projects
/
python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
065836e
)
add a test for an assertion with tuple msg
author
Benjamin Peterson
<benjamin@python.org>
Thu, 27 Oct 2011 12:20:01 +0000
(08:20 -0400)
committer
Benjamin Peterson
<benjamin@python.org>
Thu, 27 Oct 2011 12:20:01 +0000
(08:20 -0400)
Lib/test/test_raise.py
patch
|
blob
|
history
diff --git
a/Lib/test/test_raise.py
b/Lib/test/test_raise.py
index e02c1af1314d3dc51bc99b9fd24a41c08ca23040..92c50c79ee168701e040b1d8979a26b1efc7376f 100644
(file)
--- 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):