diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2013-06-12 06:28:20 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2013-06-12 06:28:20 (GMT) |
commit | f15ffe0ee5af54cb1669be8195866c6edbd5fe72 (patch) | |
tree | 9ab63f5906711bf1112c9e5c7d87792ab777b692 /Lib/test/test_unicode.py | |
parent | 6d844c5db9b826900a3cd3ea3d8ab5338df35da9 (diff) | |
parent | 31b1c8bbde529ce6c1e47259d5adf2425ca7c06f (diff) | |
download | cpython-f15ffe0ee5af54cb1669be8195866c6edbd5fe72.zip cpython-f15ffe0ee5af54cb1669be8195866c6edbd5fe72.tar.gz cpython-f15ffe0ee5af54cb1669be8195866c6edbd5fe72.tar.bz2 |
Add tests for issue #18183.
Diffstat (limited to 'Lib/test/test_unicode.py')
-rw-r--r-- | Lib/test/test_unicode.py | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/Lib/test/test_unicode.py b/Lib/test/test_unicode.py index bc34611..382b463 100644 --- a/Lib/test/test_unicode.py +++ b/Lib/test/test_unicode.py @@ -577,9 +577,6 @@ class UnicodeTest(string_tests.CommonTest, self.assertEqual('\U0008fffe'.lower(), '\U0008fffe') self.assertEqual('\u2177'.lower(), '\u2177') - # See issue #18183 for this one. - '\U00010000\U00100000'.lower() - def test_casefold(self): self.assertEqual('hello'.casefold(), 'hello') self.assertEqual('hELlo'.casefold(), 'hello') @@ -697,6 +694,17 @@ class UnicodeTest(string_tests.CommonTest, self.assertRaises(TypeError, "abc".__contains__) + def test_issue18183(self): + '\U00010000\U00100000'.lower() + '\U00010000\U00100000'.casefold() + '\U00010000\U00100000'.upper() + '\U00010000\U00100000'.capitalize() + '\U00010000\U00100000'.title() + '\U00010000\U00100000'.swapcase() + '\U00100000'.center(3, '\U00010000') + '\U00100000'.ljust(3, '\U00010000') + '\U00100000'.rjust(3, '\U00010000') + def test_format(self): self.assertEqual(''.format(), '') self.assertEqual('a'.format(), 'a') @@ -2040,6 +2048,9 @@ class UnicodeTest(string_tests.CommonTest, b'%c', c_int(0xabcd)) check_format('\U0010ffff', b'%c', c_int(0x10ffff)) + # Issue #18183 + check_format('\U00010000\U00100000', + b'%c%c', c_int(0x10000), c_int(0x100000)) # test "%" check_format('%', |