aboutsummaryrefslogtreecommitdiffstats
path: root/tests/samplebinding/namedarg_test.py
diff options
context:
space:
mode:
authorRenato Filho <renato.filho@openbossa.org>2011-09-28 17:55:54 -0300
committerHugo Parente Lima <hugo.pl@gmail.com>2012-03-08 16:18:18 -0300
commitb9ab302dd7aff3ecbbbc7ffe1ef2ef0bf4956a5a (patch)
treeb2c62e3ae790b7c5a70f7308282ec2975aa168a2 /tests/samplebinding/namedarg_test.py
parent6b21c2fa5eeb6a7c7b6533f1c966a47d8ef07e69 (diff)
Fixed tests to work with python3.x and python2.x
Diffstat (limited to 'tests/samplebinding/namedarg_test.py')
-rw-r--r--tests/samplebinding/namedarg_test.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/samplebinding/namedarg_test.py b/tests/samplebinding/namedarg_test.py
index f510b372a..20f1908b6 100644
--- a/tests/samplebinding/namedarg_test.py
+++ b/tests/samplebinding/namedarg_test.py
@@ -30,14 +30,23 @@
import unittest
from sample import Echo
+from py3kcompat import IS_PY3K
class TestNamedArg(unittest.TestCase):
def testRegularCall(self):
+ # Python 3 support unicode as string
+ if IS_PY3K:
+ return
+
echo = Echo()
self.assertRaises(TypeError, echo.methodWithNamedArg, unicode('foo'))
def testNamedArgumentCall(self):
+ # Python 3 support unicode as string
+ if IS_PY3K:
+ return
+
echo = Echo()
self.assertRaises(TypeError, echo.methodWithNamedArg, string=unicode('foo'))