Author: Antonio Cuni <[email protected]>
Branch: py3k
Changeset: r57041:40cd3c4ed930
Date: 2012-08-30 17:34 +0200
http://bitbucket.org/pypy/pypy/changeset/40cd3c4ed930/

Log:    fix test_argument now that we use again bytes string and the
        exception messages are supposed to be in utf-8

diff --git a/pypy/interpreter/test/test_argument.py 
b/pypy/interpreter/test/test_argument.py
--- a/pypy/interpreter/test/test_argument.py
+++ b/pypy/interpreter/test/test_argument.py
@@ -1,5 +1,4 @@
 # -*- coding: utf-8 -*-
-from __future__ import unicode_literals
 import py
 from pypy.interpreter.argument import (Arguments, ArgumentsForTranslation,
     ArgErr, ArgErrUnknownKwds, ArgErrMultipleValues, ArgErrCount, rawshape,
@@ -657,7 +656,7 @@
                                 [0, 3, 2],
                                 [unichr(0x1234), u'b', u'c'])
         s = err.getmsg()
-        assert s == "got an unexpected keyword argument '%s'" % unichr(0x1234)
+        assert s == "got an unexpected keyword argument '%s'" % 
unichr(0x1234).encode('utf-8')
 
     def test_multiple_values(self):
         err = ArgErrMultipleValues('bla')
@@ -686,7 +685,7 @@
         assert exc.value.message == "<lambda>() takes exactly 2 non-keyword 
arguments (0 given)"
 
     def test_unicode_keywords(self):
-        b"""
+        """
         def f(**kwargs):
             assert kwargs["&#32654;"] == 42
         f(**{"&#32654;" : 42})
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to