summaryrefslogtreecommitdiffstats
path: root/Lib/test/string_tests.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2006-06-10 06:40:50 (GMT)
committerGeorg Brandl <georg@python.org>2006-06-10 06:40:50 (GMT)
commit90e27d38f5ec7c435d32e1eebe0b7a3ad6b60216 (patch)
tree157132e2091bf19d163e1f49a43905f7a06b0306 /Lib/test/string_tests.py
parent6946ea0be032c17689ee35d3281060b8fe662471 (diff)
downloadcpython-90e27d38f5ec7c435d32e1eebe0b7a3ad6b60216.zip
cpython-90e27d38f5ec7c435d32e1eebe0b7a3ad6b60216.tar.gz
cpython-90e27d38f5ec7c435d32e1eebe0b7a3ad6b60216.tar.bz2
Apply perky's fix for #1503157: "/".join([u"", u""]) raising OverflowError.
Also improve error message on overflow.
Diffstat (limited to 'Lib/test/string_tests.py')
-rw-r--r--Lib/test/string_tests.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/string_tests.py b/Lib/test/string_tests.py
index 5a1cc8a..236c529 100644
--- a/Lib/test/string_tests.py
+++ b/Lib/test/string_tests.py
@@ -938,6 +938,8 @@ class MixinStrUnicodeUserStringTest:
# test.test_string.StringTest.test_join)
self.checkequal('a b c d', ' ', 'join', ['a', 'b', 'c', 'd'])
self.checkequal('abcd', '', 'join', ('a', 'b', 'c', 'd'))
+ self.checkequal('bd', '', 'join', ('', 'b', '', 'd'))
+ self.checkequal('ac', '', 'join', ('a', '', 'c', ''))
self.checkequal('w x y z', ' ', 'join', Sequence())
self.checkequal('abc', 'a', 'join', ('abc',))
self.checkequal('z', 'a', 'join', UserList(['z']))