mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-22 00:46:33 +03:00
More tests tweaks
Named cursors on old server versions have a different prefetch behaviour. This has hidden me the supported range of the 24:00 time format. Let's have another go at full testing...
This commit is contained in:
parent
a2a5461c28
commit
77df287e14
|
@ -309,7 +309,7 @@ class DatetimeTests(ConnectingTestCase, CommonDatetimeTestsMixin):
|
|||
from datetime import timedelta
|
||||
self._test_type_roundtrip_array(timedelta(seconds=30))
|
||||
|
||||
@skip_before_postgres(8, 4)
|
||||
@skip_before_postgres(8, 1)
|
||||
def test_time_24(self):
|
||||
from datetime import time
|
||||
|
||||
|
|
|
@ -207,6 +207,7 @@ class WithCursorTestCase(WithTestCase):
|
|||
with self.conn as conn:
|
||||
with conn.cursor('named') as cur:
|
||||
cur.execute("select 1/0")
|
||||
cur.fetchone()
|
||||
except psycopg2.DataError, e:
|
||||
self.assertEqual(e.pgcode, '22012')
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue
Block a user