From: Mike Bayer Date: Thu, 11 Mar 2010 21:34:13 +0000 (+0000) Subject: re-enable these tests X-Git-Tag: rel_0_6beta2~57^2~10 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b763015642739353bfd6a9d95061d2955e79d3e1;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git re-enable these tests --- diff --git a/lib/sqlalchemy/dialects/oracle/cx_oracle.py b/lib/sqlalchemy/dialects/oracle/cx_oracle.py index d536188da7..1748a866cb 100644 --- a/lib/sqlalchemy/dialects/oracle/cx_oracle.py +++ b/lib/sqlalchemy/dialects/oracle/cx_oracle.py @@ -213,7 +213,13 @@ class Oracle_cx_oracleExecutionContext(OracleExecutionContext): del param[fromname] if self.dialect.auto_setinputsizes: - self.set_input_sizes(quoted_bind_names) + # cx_oracle really has issues when you setinputsizes + # on String, including that outparams/RETURNING + # breaks for varchars + self.set_input_sizes(quoted_bind_names, + exclude_types=[ + self.dialect.dbapi.STRING, + self.dialect.dbapi.UNICODE]) if len(self.compiled_parameters) == 1: for key in self.compiled.binds: diff --git a/test/sql/test_returning.py b/test/sql/test_returning.py index bd0755b9d9..ba3e2ebb98 100644 --- a/test/sql/test_returning.py +++ b/test/sql/test_returning.py @@ -50,10 +50,8 @@ class ReturningTest(TestBase, AssertsExecutionResults): assert row[table.c.persons] == row['persons'] == 5 assert row[table.c.full] == row['full'] == True - @testing.fails_on('oracle+cx_oracle', 'unknown DBAPI issue') - def test(): - assert row[table.c.goofy] == row['goofy'] == "FOOsomegoofyBAR" - test() + eq_(row[table.c.goofy], row['goofy']) + eq_(row['goofy'], "FOOsomegoofyBAR") @testing.fails_on('firebird', "fb can't handle returning x AS y") @testing.exclude('firebird', '<', (2, 0), '2.0+ feature') @@ -66,7 +64,6 @@ class ReturningTest(TestBase, AssertsExecutionResults): @testing.fails_on('firebird', "fb/kintersbasdb can't handle the bind params") @testing.fails_on('oracle+zxjdbc', "JDBC driver bug") - @testing.fails_on('oracle+cx_oracle', "unknown DBAPI issue") @testing.exclude('firebird', '<', (2, 0), '2.0+ feature') @testing.exclude('postgresql', '<', (8, 2), '8.2+ feature') def test_anon_expressions(self):