Commit eddd68d5 authored by Andrew M. Kuchling's avatar Andrew M. Kuchling

As part of fixing bug #536241, add a test case for string.zfill() with Unicode

parent 102d1208
...@@ -6,7 +6,7 @@ Written by Marc-Andre Lemburg (mal@lemburg.com). ...@@ -6,7 +6,7 @@ Written by Marc-Andre Lemburg (mal@lemburg.com).
"""#" """#"
from test_support import verify, verbose, TestFailed from test_support import verify, verbose, TestFailed
import sys import sys, string
if not sys.platform.startswith('java'): if not sys.platform.startswith('java'):
# Test basic sanity of repr() # Test basic sanity of repr()
...@@ -206,6 +206,9 @@ if 0: ...@@ -206,6 +206,9 @@ if 0:
test('capwords', u'abc\tdef\nghi', u'Abc Def Ghi') test('capwords', u'abc\tdef\nghi', u'Abc Def Ghi')
test('capwords', u'abc\t def \nghi', u'Abc Def Ghi') test('capwords', u'abc\t def \nghi', u'Abc Def Ghi')
verify(string.zfill(u'34', 1) == u'34')
verify(string.zfill(u'34', 5) == u'00034')
# Comparisons: # Comparisons:
print 'Testing Unicode comparisons...', print 'Testing Unicode comparisons...',
verify(u'abc' == 'abc') verify(u'abc' == 'abc')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment