]> git.ipfire.org Git - thirdparty/sqlalchemy/alembic.git/commitdiff
Make alembic compatible with comments on constraints
authorCaselIT <cfederico87@gmail.com>
Sat, 25 Jun 2022 21:19:20 +0000 (23:19 +0200)
committerCaselIT <cfederico87@gmail.com>
Sat, 25 Jun 2022 21:21:38 +0000 (23:21 +0200)
Make alembic test compatible with comments on constraint change
added in Ia60f578595afdbd6089541c9a00e37997ef78ad3

Change-Id: I9ad803df1d3ccf2a5111266b781061936717b8c8

tests/test_batch.py

index b19fa983cc0d3afdcbb5be95689e548e3a86fb53..adf76cd5952db81479496a27b944a12a64b994ba 100644 (file)
@@ -1731,6 +1731,8 @@ class BatchRoundTripTest(TestBase):
         ck_consts[0]["sqltext"] = re.sub(
             r"[\'\"`\(\)]", "", ck_consts[0]["sqltext"]
         )
+        for ck in ck_consts:
+            ck.pop("comment", None)
         eq_(ck_consts, [{"sqltext": "x > 0", "name": "newck"}])
 
     @testing.combinations(("always",), ("auto",), argnames="recreate")