summaryrefslogtreecommitdiff
path: root/test/testbase.py
diff options
context:
space:
mode:
authorPaul Johnston <paj@pajhome.org.uk>2007-07-11 18:51:44 +0000
committerPaul Johnston <paj@pajhome.org.uk>2007-07-11 18:51:44 +0000
commit33e82c0a84d9b36333c7e7276f071fd0fc64f55d (patch)
tree0a7da43e538cf5b25cc47130ac2377926f11e2d7 /test/testbase.py
parent81fd0c8bb9af8cd3df56c7343e64c0580046ba9f (diff)
downloadsqlalchemy-33e82c0a84d9b36333c7e7276f071fd0fc64f55d.tar.gz
mssql: preliminary support for using scope_identity() with pyodbc
Diffstat (limited to 'test/testbase.py')
-rw-r--r--test/testbase.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/testbase.py b/test/testbase.py
index 335a6953d..54fcd9db2 100644
--- a/test/testbase.py
+++ b/test/testbase.py
@@ -344,6 +344,8 @@ class ExecutionContextWrapper(object):
parameters = [p.get_original_dict() for p in ctx.compiled_parameters]
query = self.convert_statement(query)
+ if db.engine.name == 'mssql' and statement.endswith('; select scope_identity()'):
+ statement = statement[:-25]
testdata.unittest.assert_(statement == query and (params is None or params == parameters), "Testing for query '%s' params %s, received '%s' with params %s" % (query, repr(params), statement, repr(parameters)))
testdata.sql_count += 1
self.ctx.post_exec()