diff options
author | Catalin Iacob <iacobcatalin@gmail.com> | 2013-03-15 18:10:13 +0100 |
---|---|---|
committer | Daniele Varrazzo <daniele.varrazzo@gmail.com> | 2013-03-16 00:54:11 +0000 |
commit | 7abe1775d0bc037494576691172ece437dea3761 (patch) | |
tree | 8aa230c02105697a63567fb219094e13c7930465 /tests/test_async.py | |
parent | 7f86529183048a7ad87e3dc300a8f0857b96690a (diff) | |
download | psycopg2-7abe1775d0bc037494576691172ece437dea3761.tar.gz |
Fix tests for Postgres 9.3
Postgres 9.3 turns messages about implicit indexes and sequences from NOTICE
to DEBUG1 so the tests fail with a default 9.3 server configuration because
the client doesn't get any NOTICE. Fix it by also asking for DEBUG1 messages
from the server when testing against Postgres >= 9.3.
Diffstat (limited to 'tests/test_async.py')
-rwxr-xr-x | tests/test_async.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/test_async.py b/tests/test_async.py index 08113c4..b51429f 100755 --- a/tests/test_async.py +++ b/tests/test_async.py @@ -429,6 +429,9 @@ class AsyncTests(unittest.TestCase): def test_notices(self): del self.conn.notices[:] cur = self.conn.cursor() + if self.conn.server_version >= 90300: + cur.execute("set client_min_messages=debug1") + self.wait(cur) cur.execute("create temp table chatty (id serial primary key);") self.wait(cur) self.assertEqual("CREATE TABLE", cur.statusmessage) |