From: Benjamin Peterson Date: Thu, 27 Oct 2011 12:20:01 +0000 (-0400) Subject: add a test for an assertion with tuple msg X-Git-Tag: v3.3.0a1~1053 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2f8dfcd6f4553d3d0063e32a1a9a3d98f5119dcd;p=thirdparty%2FPython%2Fcpython.git add a test for an assertion with tuple msg --- diff --git a/Lib/test/test_raise.py b/Lib/test/test_raise.py index e02c1af1314d..92c50c79ee16 100644 --- a/Lib/test/test_raise.py +++ b/Lib/test/test_raise.py @@ -130,6 +130,13 @@ class TestRaise(unittest.TestCase): with self.assertRaises(TypeError): raise MyException + def test_assert_with_tuple_arg(self): + try: + assert False, (3,) + except AssertionError as e: + self.assertEqual(str(e), "(3,)") + + class TestCause(unittest.TestCase): def test_invalid_cause(self):