From c3fcf4d928b7772e5e2152ac0717480ed699041d Mon Sep 17 00:00:00 2001 From: holger krekel Date: Thu, 5 Sep 2013 22:22:14 +0200 Subject: [PATCH] show more info if the test fails --- testing/test_runner.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/testing/test_runner.py b/testing/test_runner.py index fcd524f0c..dd5997170 100644 --- a/testing/test_runner.py +++ b/testing/test_runner.py @@ -185,7 +185,10 @@ class BaseFunctionalTests: # so we would end up calling test functions while # sys.exc_info would return the indexerror # from guessing the lastitem - assert sys.exc_info()[0] is None + excinfo = sys.exc_info() + import traceback + assert excinfo[0] is None, \ + traceback.format_exception(*excinfo) def teardown_function(func): raise ValueError(42) """)