From: Victor Stinner Date: Thu, 31 Mar 2011 17:07:58 +0000 (+0200) Subject: Issue #11393: get more information on assertion error (test_faulthandler) X-Git-Tag: v3.3.0a1~2711 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=eb50e51a0fd6e182a7543eddfe039226b1a80262;p=python Issue #11393: get more information on assertion error (test_faulthandler) --- diff --git a/Lib/test/test_faulthandler.py b/Lib/test/test_faulthandler.py index 1a3f5e2400..1da5cae7f1 100644 --- a/Lib/test/test_faulthandler.py +++ b/Lib/test/test_faulthandler.py @@ -354,7 +354,7 @@ def func(repeat, cancel, timeout): faulthandler.cancel_dump_tracebacks_later() b = time.time() # Check that sleep() was not interrupted - assert (b -a) >= pause + assert (b - a) >= pause, "{{}} < {{}}".format(b - a, pause) if cancel: pause = timeout * 1.5 @@ -362,7 +362,7 @@ def func(repeat, cancel, timeout): time.sleep(pause) b = time.time() # Check that sleep() was not interrupted - assert (b -a) >= pause + assert (b - a) >= pause, "{{}} < {{}}".format(b - a, pause) timeout = 0.5 repeat = {repeat}