From: Michael W. Hudson Date: Mon, 20 May 2002 14:54:17 +0000 (+0000) Subject: Guess what? --disable-unicode proofing. X-Git-Tag: v2.3c1~5639 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7b7ba540332b9a62be622035dc69b2a332ce6c68;p=python Guess what? --disable-unicode proofing. This is a strange test. --- diff --git a/Lib/test/test_getargs.py b/Lib/test/test_getargs.py index ed6e4eebf3..ff0d36cf57 100644 --- a/Lib/test/test_getargs.py +++ b/Lib/test/test_getargs.py @@ -14,8 +14,11 @@ single case that failed between 2.1 and 2.2a2. # XXX If the encoding succeeds using the current default encoding, # this test will fail because it does not test the right part of the # PyArg_ParseTuple() implementation. +from test_support import have_unicode import marshal -try: - marshal.loads(u"\222") -except UnicodeError: - pass + +if have_unicode: + try: + marshal.loads(unicode(r"\222", 'unicode-escape')) + except UnicodeError: + pass