Skip to content

Commit 55a5193

Browse files
committed
extended test_alter_column_set_type to also test running migrations in reverse
1 parent 86521dc commit 55a5193

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/apps/migrations/auto/test_migration_manager.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -515,12 +515,17 @@ def test_alter_column_set_type(self):
515515
)
516516

517517
asyncio.run(manager.run())
518-
519518
column_type_str = self.get_postgres_column_type(
520519
tablename="manager", column_name="name"
521520
)
522521
self.assertEqual(column_type_str, "TEXT")
523522

523+
asyncio.run(manager.run_backwards())
524+
column_type_str = self.get_postgres_column_type(
525+
tablename="manager", column_name="name"
526+
)
527+
self.assertEqual(column_type_str, "CHARACTER VARYING")
528+
524529
@postgres_only
525530
def test_alter_column_set_length(self):
526531
"""

0 commit comments

Comments
 (0)