diff options
Diffstat (limited to 'Lib/test/string_tests.py')
-rw-r--r-- | Lib/test/string_tests.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/string_tests.py b/Lib/test/string_tests.py index b1b64a8..f2c9579 100644 --- a/Lib/test/string_tests.py +++ b/Lib/test/string_tests.py @@ -2,7 +2,7 @@ Common tests shared by test_str, test_unicode, test_userstring and test_string. """ -import unittest, string, sys +import unittest, string, sys, struct from test import test_support from UserList import UserList @@ -507,7 +507,7 @@ class BaseTest(unittest.TestCase): def test_replace_overflow(self): # Check for overflow checking on 32 bit machines - if sys.maxint != 2147483647: + if sys.maxint != 2147483647 or struct.calcsize("P") > 4: return A2_16 = "A" * (2**16) self.checkraises(OverflowError, A2_16, "replace", "", A2_16) |