From a6892418ad1605bf5f7f669176c68b8738f9f776 Mon Sep 17 00:00:00 2001 From: Alexander Belopolsky Date: Tue, 11 Jan 2011 02:22:16 +0000 Subject: [PATCH] This should fix mktime test on Windows --- Lib/test/test_time.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Lib/test/test_time.py b/Lib/test/test_time.py index 574a867ce20..7266e27295f 100644 --- a/Lib/test/test_time.py +++ b/Lib/test/test_time.py @@ -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.