[Python-checkins] cpython (merge 3.3 -> 3.3): Merge heads.
ezio.melotti
python-checkins at python.org
Wed Feb 20 23:01:58 CET 2013
http://hg.python.org/cpython/rev/519ad21e12c4
changeset: 82286:519ad21e12c4
branch: 3.3
parent: 82282:470350fd2831
parent: 82285:7f34f8fa799d
user: Ezio Melotti <ezio.melotti at gmail.com>
date: Thu Feb 21 00:00:17 2013 +0200
summary:
Merge heads.
files:
Lib/test/test_unicode.py | 18 ++++++++++--------
1 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/Lib/test/test_unicode.py b/Lib/test/test_unicode.py
--- a/Lib/test/test_unicode.py
+++ b/Lib/test/test_unicode.py
@@ -2172,15 +2172,17 @@
# generate a fresh string (refcount=1)
text = 'a' * length + 'b'
- # fill wstr internal field
- abc = text.encode('unicode_internal')
- self.assertEqual(abc.decode('unicode_internal'), text)
+ with support.check_warnings(('unicode_internal codec has been '
+ 'deprecated', DeprecationWarning)):
+ # fill wstr internal field
+ abc = text.encode('unicode_internal')
+ self.assertEqual(abc.decode('unicode_internal'), text)
- # resize text: wstr field must be cleared and then recomputed
- text += 'c'
- abcdef = text.encode('unicode_internal')
- self.assertNotEqual(abc, abcdef)
- self.assertEqual(abcdef.decode('unicode_internal'), text)
+ # resize text: wstr field must be cleared and then recomputed
+ text += 'c'
+ abcdef = text.encode('unicode_internal')
+ self.assertNotEqual(abc, abcdef)
+ self.assertEqual(abcdef.decode('unicode_internal'), text)
class StringModuleTest(unittest.TestCase):
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list