[Python-checkins] r87748 - python/branches/py3k/Lib/test/test_time.py

antoine.pitrou python-checkins at python.org
Tue Jan 4 23:54:31 CET 2011


Author: antoine.pitrou
Date: Tue Jan  4 23:54:30 2011
New Revision: 87748

Log:
Fix test_time under Windows



Modified:
   python/branches/py3k/Lib/test/test_time.py

Modified: python/branches/py3k/Lib/test/test_time.py
==============================================================================
--- python/branches/py3k/Lib/test/test_time.py	(original)
+++ python/branches/py3k/Lib/test/test_time.py	Tue Jan  4 23:54:30 2011
@@ -124,7 +124,7 @@
         time.asctime(time.gmtime(self.t))
 
         # Max year is only limited by the size of C int.
-        sizeof_int = sysconfig.get_config_vars('SIZEOF_INT')[0]
+        sizeof_int = sysconfig.get_config_var('SIZEOF_INT') or 4
         bigyear = (1 << 8 * sizeof_int - 1) - 1
         asc = time.asctime((bigyear, 6, 1) + (0,)*6)
         self.assertEqual(asc[-len(str(bigyear)):], str(bigyear))


More information about the Python-checkins mailing list