From d0e78b044e795888baa3718a654c34f5744ca344 Mon Sep 17 00:00:00 2001 From: Paul Johnston Date: Tue, 14 Aug 2007 18:16:27 +0000 Subject: [PATCH] fudge to make SQL asserts work reliably with MSSQL --- test/testlib/testing.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/testlib/testing.py b/test/testlib/testing.py index 9ee2012021..e56a1d36fc 100644 --- a/test/testlib/testing.py +++ b/test/testlib/testing.py @@ -258,6 +258,8 @@ class AssertMixin(PersistTest): def assert_sql(self, db, callable_, list, with_sequences=None): global testdata testdata = TestData() + if config.db.name == 'mssql': + list = [s.endswith('; select scope_identity()') and s[:-25] or s for s in list] if with_sequences is not None and (config.db.name == 'postgres' or config.db.name == 'oracle'): testdata.set_assert_list(self, with_sequences) -- 2.47.3