MCPcopy
hub / github.com/django/django / test_run_before

Method test_run_before

tests/migrations/test_loader.py:169–182  ·  view source on GitHub ↗

Makes sure the loader uses Migration.run_before.

(self)

Source from the content-addressed store, hash-verified

167 MIGRATION_MODULES={"migrations": "migrations.test_migrations_run_before"}
168 )
169 def test_run_before(self):
170 """
171 Makes sure the loader uses Migration.run_before.
172 """
173 # Load and test the plan
174 migration_loader = MigrationLoader(connection)
175 self.assertEqual(
176 migration_loader.graph.forwards_plan(("migrations", "0002_second")),
177 [
178 ("migrations", "0001_initial"),
179 ("migrations", "0003_third"),
180 ("migrations", "0002_second"),
181 ],
182 )
183
184 @override_settings(
185 MIGRATION_MODULES={

Callers

nothing calls this directly

Calls 2

MigrationLoaderClass · 0.90
forwards_planMethod · 0.80

Tested by

no test coverage detected