summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorFlorent Xicluna <florent.xicluna@gmail.com>2011-11-01 22:42:05 (GMT)
committerFlorent Xicluna <florent.xicluna@gmail.com>2011-11-01 22:42:05 (GMT)
commitd1bd7f77303d08652b5f67c7385125c3d0ec9209 (patch)
treef513ee6c4a959773bdc53c94a0e04945f39e124c /Lib
parentf24e7e6c4154178dc8409e4caee33777e166f949 (diff)
downloadcpython-d1bd7f77303d08652b5f67c7385125c3d0ec9209.zip
cpython-d1bd7f77303d08652b5f67c7385125c3d0ec9209.tar.gz
cpython-d1bd7f77303d08652b5f67c7385125c3d0ec9209.tar.bz2
Additional tests for negative years.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_time.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_time.py b/Lib/test/test_time.py
index 003856a..0e89904 100644
--- a/Lib/test/test_time.py
+++ b/Lib/test/test_time.py
@@ -423,6 +423,8 @@ class _Test4dYear(_BaseYearTest):
self.assertEqual(self.yearstr(-1), self._format % -1)
self.assertEqual(self.yearstr(-1234), '-1234')
self.assertEqual(self.yearstr(-123456), '-123456')
+ self.assertEqual(self.yearstr(-123456789), str(-123456789))
+ self.assertEqual(self.yearstr(-1234567890), str(-1234567890))
self.assertEqual(self.yearstr(TIME_MINYEAR), str(TIME_MINYEAR))
self.assertRaises(OverflowError, self.yearstr, TIME_MINYEAR - 1)