mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
Rename the surrogates error handler to surrogatepass.
This commit is contained in:
parent
cf7925dfc6
commit
e0a2b72e61
6 changed files with 25 additions and 25 deletions
|
@ -906,10 +906,10 @@ class UnicodeTest(
|
|||
self.assertEqual('\u20ac'.encode('utf-8'), b'\xe2\x82\xac')
|
||||
self.assertEqual('\ud800\udc02'.encode('utf-8'), b'\xf0\x90\x80\x82')
|
||||
self.assertEqual('\ud84d\udc56'.encode('utf-8'), b'\xf0\xa3\x91\x96')
|
||||
self.assertEqual('\ud800'.encode('utf-8', 'surrogates'), b'\xed\xa0\x80')
|
||||
self.assertEqual('\udc00'.encode('utf-8', 'surrogates'), b'\xed\xb0\x80')
|
||||
self.assertEqual('\ud800'.encode('utf-8', 'surrogatepass'), b'\xed\xa0\x80')
|
||||
self.assertEqual('\udc00'.encode('utf-8', 'surrogatepass'), b'\xed\xb0\x80')
|
||||
self.assertEqual(
|
||||
('\ud800\udc02'*1000).encode('utf-8', 'surrogates'),
|
||||
('\ud800\udc02'*1000).encode('utf-8', 'surrogatepass'),
|
||||
b'\xf0\x90\x80\x82'*1000
|
||||
)
|
||||
self.assertEqual(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue