mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-22 08:56:34 +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
7ea56b112e
commit
296caa4556
|
@ -319,7 +319,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