diff options
| author | Tim Graham <timograham@gmail.com> | 2014-09-17 19:45:42 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-09-18 09:00:55 -0400 |
| commit | 8facb02faf1880187888b26724760865547b05b0 (patch) | |
| tree | 6c4e5020bf6b2e41715291e8ab9537408fd20b98 | |
| parent | 33e817a6d8b163aa6e8a2fb15d7269d1ecbbcf59 (diff) | |
Improved GIS migration test cleanup; refs #23504.
| -rw-r--r-- | django/contrib/gis/tests/gis_migrations/test_operations.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/contrib/gis/tests/gis_migrations/test_operations.py b/django/contrib/gis/tests/gis_migrations/test_operations.py index 6db2e2db30..d44c22c134 100644 --- a/django/contrib/gis/tests/gis_migrations/test_operations.py +++ b/django/contrib/gis/tests/gis_migrations/test_operations.py @@ -64,6 +64,7 @@ class OperationTests(TransactionTestCase): operation.state_forwards("gis", new_state) with connection.schema_editor() as editor: operation.database_forwards("gis", editor, project_state, new_state) + self.current_state = new_state self.assertColumnExists("gis_neighborhood", "path") # Test GeometryColumns when available @@ -72,7 +73,6 @@ class OperationTests(TransactionTestCase): GeometryColumns.objects.filter(**{GeometryColumns.table_name_col(): "gis_neighborhood"}).count(), 2 ) - self.current_state = new_state def test_remove_gis_field(self): """ @@ -84,6 +84,7 @@ class OperationTests(TransactionTestCase): operation.state_forwards("gis", new_state) with connection.schema_editor() as editor: operation.database_forwards("gis", editor, project_state, new_state) + self.current_state = new_state self.assertColumnNotExists("gis_neighborhood", "geom") # Test GeometryColumns when available @@ -92,4 +93,3 @@ class OperationTests(TransactionTestCase): GeometryColumns.objects.filter(**{GeometryColumns.table_name_col(): "gis_neighborhood"}).count(), 0 ) - self.current_state = new_state |
