summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>2018-01-11 08:52:03 +0900
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>2018-01-10 23:58:28 +0000
commita78ac3c1253717f1f0f8f87f0c868e54f42af440 (patch)
tree56c416baa5386a78683c2b1dc42990fed4b7c770
parent04f1f06b9f1f627436c1202aaa45434334c8747d (diff)
downloadpsycopg2-a78ac3c1253717f1f0f8f87f0c868e54f42af440.tar.gz
Fixed test in asian time zones
Fix #652
-rwxr-xr-xtests/test_dates.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/test_dates.py b/tests/test_dates.py
index 47ef41c..74dfc9a 100755
--- a/tests/test_dates.py
+++ b/tests/test_dates.py
@@ -639,7 +639,8 @@ class FromTicksTestCase(unittest.TestCase):
def test_date_value_error_sec_59_99(self):
from datetime import date
s = psycopg2.DateFromTicks(1273173119.99992)
- self.assertEqual(s.adapted, date(2010, 5, 6))
+ # The returned date is local
+ self.assert_(s.adapted in [date(2010, 5, 6), date(2010, 5, 7)])
def test_time_value_error_sec_59_99(self):
from datetime import time