summaryrefslogtreecommitdiff
path: root/test/dialect
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2015-03-02 19:00:19 -0500
committerMike Bayer <mike_mp@zzzcomputing.com>2015-03-02 19:00:19 -0500
commitd140983148f1acbee7606a037bdf0a9f144cd173 (patch)
tree2d9a2e3dfe9a2a94d0d7110c2c15156c5d8b7c1d /test/dialect
parent79cbd377a62d291103aa0e378f0665e2e09185b2 (diff)
parent17e03a0ea86cd92816b4002a203b2b0b2c1a538a (diff)
downloadsqlalchemy-d140983148f1acbee7606a037bdf0a9f144cd173.tar.gz
Merge remote-tracking branch 'origin/pr/132' into pr132
Diffstat (limited to 'test/dialect')
-rw-r--r--test/dialect/postgresql/test_dialect.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/test/dialect/postgresql/test_dialect.py b/test/dialect/postgresql/test_dialect.py
index 9f86aaa7a..bdd292fff 100644
--- a/test/dialect/postgresql/test_dialect.py
+++ b/test/dialect/postgresql/test_dialect.py
@@ -99,11 +99,13 @@ class MiscTest(fixtures.TestBase, AssertsExecutionResults, AssertsCompiledSQL):
assert 'will create implicit sequence' in msgs
assert 'will create implicit index' in msgs
- @testing.only_on('postgresql+psycopg2', 'psycopg2-specific feature')
+ @testing.only_on(
+ ['postgresql+psycopg2', 'postgresql+pg8000'],
+ 'psycopg2/pg8000-specific feature')
@engines.close_open_connections
def test_client_encoding(self):
c = testing.db.connect()
- current_encoding = c.connection.connection.encoding
+ current_encoding = c.execute("show client_encoding").fetchone()[0]
c.close()
# attempt to use an encoding that's not
@@ -115,7 +117,8 @@ class MiscTest(fixtures.TestBase, AssertsExecutionResults, AssertsCompiledSQL):
e = engines.testing_engine(options={'client_encoding': test_encoding})
c = e.connect()
- eq_(c.connection.connection.encoding, test_encoding)
+ new_encoding = c.execute("show client_encoding").fetchone()[0]
+ eq_(new_encoding, test_encoding)
@testing.only_on(
['postgresql+psycopg2', 'postgresql+pg8000',