From a9da5dd5b6f722a230a69211ad8e00a20cafcd38 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 29 Dec 2014 16:23:18 -0500 Subject: [1.7.x] Fixed #23581 -- Prevented extraneous DROP DEFAULT statements. Thanks john_scott for the report and Markus Holtermann for review. Backport of ab4f709da4516672b0bd811f2b4d0c4ba9f5b636 from master --- tests/schema/tests.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tests') diff --git a/tests/schema/tests.py b/tests/schema/tests.py index 077c41611f..d7db1f8949 100644 --- a/tests/schema/tests.py +++ b/tests/schema/tests.py @@ -554,6 +554,10 @@ class SchemaTests(TransactionTestCase): strict=True, ) + # This will fail if DROP DEFAULT is inadvertently executed on this + # field which drops the id sequence, at least on PostgreSQL. + Author.objects.create(name='Foo') + def test_rename(self): """ Tests simple altering of fields -- cgit v1.3