]> granicus.if.org Git - python/commitdiff
It appears that unittest was changed to stop hoarding raw exception data,
authorTim Peters <tim.peters@gmail.com>
Sat, 8 Sep 2001 03:37:56 +0000 (03:37 +0000)
committerTim Peters <tim.peters@gmail.com>
Sat, 8 Sep 2001 03:37:56 +0000 (03:37 +0000)
saving instead a traceback string, but test_support's run_unittest was
still peeking into unittest internals and trying to pick apart unittest's
errors and failures vectors as if they contained exc_info() tuples instead
of strings.
Whatever, when a unittest-based test failed, test_support blew up.  I'm
not sure this is the right way to fix it; it simply gets me unstuck.

Lib/test/test_support.py

index 5391f68c12f57fb65a6bd76fc623bf5da9f9667a..0e87131cfbe4f05c3ea215ece27f78b2c5662634 100644 (file)
@@ -155,7 +155,4 @@ def run_unittest(testclass):
         else:
             raise TestFailed("errors occurred in %s.%s"
                              % (testclass.__module__, testclass.__name__))
-        if err[0] is AssertionError:
-            raise TestFailed(str(err[1]))
-        else:
-            raise TestFailed("%s: %s" % err[:2])
+        raise TestFailed(err)