Skip test under 64-bit Windows

This commit is contained in:
Antoine Pitrou 2012-05-16 14:50:25 +02:00
parent e3d8ab6d38
commit 4cf3f69250
1 changed files with 4 additions and 1 deletions

View File

@ -125,7 +125,10 @@ class TestBisect(unittest.TestCase):
def test_large_range(self):
# Issue 13496
mod = self.module
data = xrange(sys.maxsize-1)
try:
data = xrange(sys.maxsize-1)
except OverflowError:
self.skipTest("can't create a xrange() object of size `sys.maxsize`")
self.assertEqual(mod.bisect_left(data, sys.maxsize-3), sys.maxsize-3)
self.assertEqual(mod.bisect_right(data, sys.maxsize-3), sys.maxsize-2)