diff options
author | Erik Johnston <erik@matrix.org> | 2023-07-10 16:24:42 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-10 16:24:42 +0100 |
commit | e55a9b3e41e73f34fda781b9374935c4623f7ea9 (patch) | |
tree | 6cfa8859ae42ed28cf12470586cd3a7539e1da5f /tests/storage | |
parent | Fix building rust with nightly (#15906) (diff) | |
download | synapse-e55a9b3e41e73f34fda781b9374935c4623f7ea9.tar.xz |
Fix downgrading to previous version of Synapse (#15907)
We do this by marking the constraint as deferrable.
Diffstat (limited to 'tests/storage')
-rw-r--r-- | tests/storage/test_background_update.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/storage/test_background_update.py b/tests/storage/test_background_update.py index 6ca546f3f7..a4a823a252 100644 --- a/tests/storage/test_background_update.py +++ b/tests/storage/test_background_update.py @@ -586,7 +586,9 @@ class BackgroundUpdateValidateConstraintTestCase(unittest.HomeserverTestCase): update_name="test_bg_update", table="test_constraint", constraint_name="test_constraint_name", - constraint=ForeignKeyConstraint("base_table", [("b", "b")]), + constraint=ForeignKeyConstraint( + "base_table", [("b", "b")], deferred=False + ), sqlite_table_name="test_constraint2", sqlite_table_schema=table2_sqlite, ) @@ -604,7 +606,9 @@ class BackgroundUpdateValidateConstraintTestCase(unittest.HomeserverTestCase): "test_bg_update", table="test_constraint", constraint_name="test_constraint_name", - constraint=ForeignKeyConstraint("base_table", [("b", "b")]), + constraint=ForeignKeyConstraint( + "base_table", [("b", "b")], deferred=False + ), unique_columns=["a"], ) |