mirror of https://github.com/python/cpython
gh-123849: Fix test_sqlite3.test_table_dump when foreign keys are enabled by default (#123859)
This commit is contained in:
parent
37228bd16e
commit
14b44c58e1
|
@ -10,6 +10,7 @@ class DumpTests(MemoryDatabaseMixin, unittest.TestCase):
|
|||
|
||||
def test_table_dump(self):
|
||||
expected_sqls = [
|
||||
"PRAGMA foreign_keys=OFF;",
|
||||
"""CREATE TABLE "index"("index" blob);"""
|
||||
,
|
||||
"""INSERT INTO "index" VALUES(X'01');"""
|
||||
|
@ -48,7 +49,7 @@ class DumpTests(MemoryDatabaseMixin, unittest.TestCase):
|
|||
expected_sqls = [
|
||||
"PRAGMA foreign_keys=OFF;",
|
||||
"BEGIN TRANSACTION;",
|
||||
*expected_sqls,
|
||||
*expected_sqls[1:],
|
||||
"COMMIT;",
|
||||
]
|
||||
[self.assertEqual(expected_sqls[i], actual_sqls[i])
|
||||
|
|
Loading…
Reference in New Issue