This should fix mktime test on Windows

This commit is contained in:
Alexander Belopolsky 2011-01-11 02:22:16 +00:00
parent 31c5dd6b19
commit a6892418ad
1 changed files with 2 additions and 1 deletions

View File

@ -347,7 +347,8 @@ class _Test4dYear(_BaseYearTest):
tt = time.localtime(t)
except (OverflowError, ValueError):
pass
self.assertEqual(time.mktime(tt), t)
else:
self.assertEqual(time.mktime(tt), t)
# It may not be possible to reliably make mktime return error
# on all platfom. This will make sure that no other exception
# than OverflowError is raised for an extreme value.