]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
run test_update_rowcount_return_defaults only w/ returning
authorMike Bayer <mike_mp@zzzcomputing.com>
Mon, 6 Jun 2022 14:58:59 +0000 (10:58 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 6 Jun 2022 14:58:59 +0000 (10:58 -0400)
sane_rowcount_w_returning asserts failure, which will only
occur here if the DBAPI actually uses RETURNING.

as SQLite conditionally supports RETURNING which breaks
rowcount support only if present, limit this test to that
case.

Additionally, newer pysqlites will likely fix the issue so
we will probably want to put a sqlite3_version check as well
once that fix is released.

Change-Id: I065aa181eb48363c1024550ae3622486ae0b4a6e

lib/sqlalchemy/testing/suite/test_rowcount.py

index d1bf9ae154d357b21d330ac717c19cf4c7bf7f1f..b7d4b7452f9f55da4b041b6323227b36d1812787 100644 (file)
@@ -88,6 +88,7 @@ class RowCountTest(fixtures.TablesTest):
         )
         eq_(r.rowcount, 3)
 
+    @testing.requires.update_returning
     @testing.requires.sane_rowcount_w_returning
     def test_update_rowcount_return_defaults(self, connection):
         employees_table = self.tables.employees