Issue #16979: Fix error handling bugs in the unicode-escape-decode decoder.

This commit is contained in:
Serhiy Storchaka 2013-01-29 10:20:44 +02:00
parent 8e0ae2a4f0
commit d679377be7
4 changed files with 117 additions and 53 deletions

View file

@ -262,12 +262,12 @@ class CodecCallbackTest(unittest.TestCase):
self.assertEqual(
b"\\u3042\u3xxx".decode("unicode-escape", "test.handler1"),
"\u3042[<92><117><51><120>]xx"
"\u3042[<92><117><51>]xxx"
)
self.assertEqual(
b"\\u3042\u3xx".decode("unicode-escape", "test.handler1"),
"\u3042[<92><117><51><120><120>]"
"\u3042[<92><117><51>]xx"
)
self.assertEqual(