summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSylvain <syt@logilab.fr>2007-09-11 12:51:54 +0200
committerSylvain <syt@logilab.fr>2007-09-11 12:51:54 +0200
commitd66cc9ebb3c96bb6a3022a1f80b1033af09ee8d7 (patch)
treeee51d3e61989d26fb249dbf583a23366edf3a11f
parent74050982985a5ac74b35f5a0ae0955c050ffdf85 (diff)
downloadlogilab-common-d66cc9ebb3c96bb6a3022a1f80b1033af09ee8d7.tar.gz
nicer assertIsInstance error message
-rw-r--r--testlib.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/testlib.py b/testlib.py
index cb98e90..23aee4a 100644
--- a/testlib.py
+++ b/testlib.py
@@ -1113,7 +1113,7 @@ class TestCase(unittest.TestCase):
def assertIsInstance(self, obj, klass, msg=None):
"""compares two files using difflib"""
if msg is None:
- msg = '%s is not an instance of %s' % (obj, klass)
+ msg = '%s is not an instance of %s but of %s' % (obj, klass, type(obj))
self.assert_(isinstance(obj, klass), msg)