summaryrefslogtreecommitdiff
path: root/tests/test_mysql.py
diff options
context:
space:
mode:
authorergo <none@none>2012-07-18 00:35:08 +0200
committerergo <none@none>2012-07-18 00:35:08 +0200
commitbbe847d5b8932d9c113d659a2807678aa8777ea1 (patch)
tree368d31be151e2dd2e8b8e52127dbdc22f94613c0 /tests/test_mysql.py
parent62b664fab8ab12aa9bb19cefd982c47e12d0bf57 (diff)
downloadalembic-bbe847d5b8932d9c113d659a2807678aa8777ea1.tar.gz
added drop primary key constraint
Diffstat (limited to 'tests/test_mysql.py')
-rw-r--r--tests/test_mysql.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_mysql.py b/tests/test_mysql.py
index 4c4a357..548217e 100644
--- a/tests/test_mysql.py
+++ b/tests/test_mysql.py
@@ -48,6 +48,13 @@ def test_drop_fk():
"ALTER TABLE t1 DROP FOREIGN KEY f1"
)
+def test_drop_constraint_primary():
+ context = op_fixture('mysql')
+ op.drop_constraint('primary', 't1',type='primary')
+ context.assert_(
+ "ALTER TABLE t1 DROP PRIMARY KEY "
+ )
+
def test_drop_unique():
context = op_fixture('mysql')
op.drop_constraint("f1", "t1", "unique")