summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_unicode.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_unicode.py')
-rw-r--r--Lib/test/test_unicode.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/test/test_unicode.py b/Lib/test/test_unicode.py
index 003ff18..b1f7c89 100644
--- a/Lib/test/test_unicode.py
+++ b/Lib/test/test_unicode.py
@@ -465,6 +465,13 @@ class UnicodeTest(string_tests.CommonTest,
self.checkraises(TypeError, ' ', 'join', [1, 2, 3])
self.checkraises(TypeError, ' ', 'join', ['1', '2', 3])
+ @unittest.skipIf(sys.maxsize > 2**32,
+ 'needs too much memory on a 64-bit platform')
+ def test_join_overflow(self):
+ size = int(sys.maxsize**0.5) + 1
+ seq = ('A' * size,) * size
+ self.assertRaises(OverflowError, ''.join, seq)
+
def test_replace(self):
string_tests.CommonTest.test_replace(self)