mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-22 17:06:33 +03:00
Fixed test_dates failures in older version of Python
This commit is contained in:
parent
e8ef973ddf
commit
8e54f7dcce
|
@ -1,5 +1,8 @@
|
|||
2009-04-01 Federico Di Gregorio <fog@initd.org>
|
||||
|
||||
* Applied patch from Menno Smits to fix failures in test_dates
|
||||
when executed in older version of Python.
|
||||
|
||||
* Applied patch from Menno Smits to fix lobject test failures.
|
||||
|
||||
2009-03-08 Federico Di Gregorio <fog@initd.org>
|
||||
|
|
|
@ -153,5 +153,4 @@
|
|||
<File name="psycopg/adapter_pfloat.h" subtype="Code" buildaction="Nothing" />
|
||||
</Contents>
|
||||
<compiler ctype="GccCompiler" />
|
||||
<MonoDevelop.ChangeLogAddIn.ChangeLogInfo policy="UpdateNearestChangeLog" />
|
||||
</Project>
|
|
@ -131,7 +131,7 @@ class DatetimeTests(unittest.TestCase, CommonDatetimeTestsMixin):
|
|||
try:
|
||||
self.check_time_tz("+01:15:42", 4542)
|
||||
except ValueError, exc:
|
||||
self.assertEqual(exc.message, "time zone offset 4542 is not a "
|
||||
self.assertEqual(str(exc), "time zone offset 4542 is not a "
|
||||
"whole number of minutes")
|
||||
else:
|
||||
self.fail("Expected ValueError")
|
||||
|
@ -139,7 +139,7 @@ class DatetimeTests(unittest.TestCase, CommonDatetimeTestsMixin):
|
|||
try:
|
||||
self.check_time_tz("-01:15:42", -4542)
|
||||
except ValueError, exc:
|
||||
self.assertEqual(exc.message, "time zone offset -4542 is not a "
|
||||
self.assertEqual(str(exc), "time zone offset -4542 is not a "
|
||||
"whole number of minutes")
|
||||
else:
|
||||
self.fail("Expected ValueError")
|
||||
|
@ -175,7 +175,7 @@ class DatetimeTests(unittest.TestCase, CommonDatetimeTestsMixin):
|
|||
try:
|
||||
self.check_datetime_tz("+01:15:42", 4542)
|
||||
except ValueError, exc:
|
||||
self.assertEqual(exc.message, "time zone offset 4542 is not a "
|
||||
self.assertEqual(str(exc), "time zone offset 4542 is not a "
|
||||
"whole number of minutes")
|
||||
else:
|
||||
self.fail("Expected ValueError")
|
||||
|
@ -183,7 +183,7 @@ class DatetimeTests(unittest.TestCase, CommonDatetimeTestsMixin):
|
|||
try:
|
||||
self.check_datetime_tz("-01:15:42", -4542)
|
||||
except ValueError, exc:
|
||||
self.assertEqual(exc.message, "time zone offset -4542 is not a "
|
||||
self.assertEqual(str(exc), "time zone offset -4542 is not a "
|
||||
"whole number of minutes")
|
||||
else:
|
||||
self.fail("Expected ValueError")
|
||||
|
|
Loading…
Reference in New Issue
Block a user