summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/pickletester.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/Lib/test/pickletester.py b/Lib/test/pickletester.py
index c7c89d1..f65093a 100644
--- a/Lib/test/pickletester.py
+++ b/Lib/test/pickletester.py
@@ -484,13 +484,21 @@ class AbstractPickleTests(unittest.TestCase):
self.assertRaises(ValueError, self.loads, buf)
def test_unicode(self):
- endcases = ['', '<\\u>', '<\\\u1234>', '<\n>', '<\\>']
+ endcases = ['', '<\\u>', '<\\\u1234>', '<\n>', '<\\>',
+ '<\\\U00012345>']
for proto in protocols:
for u in endcases:
p = self.dumps(u, proto)
u2 = self.loads(p)
self.assertEqual(u2, u)
+ def test_unicode_high_plane(self):
+ t = '\U00012345'
+ for proto in protocols:
+ p = self.dumps(t, proto)
+ t2 = self.loads(p)
+ self.assertEqual(t2, t)
+
def test_bytes(self):
for proto in protocols:
for u in b'', b'xyz', b'xyz'*100: