Better error reporting in test_math.py

This commit is contained in:
Mark Dickinson 2008-05-23 03:30:01 +00:00
parent c11c3391b0
commit d055835253
1 changed files with 4 additions and 0 deletions

View File

@ -902,6 +902,10 @@ class MathTests(unittest.TestCase):
message = ("Unexpected ValueError in " + message = ("Unexpected ValueError in " +
"test %s:%s(%r)\n" % (id, fn, ar)) "test %s:%s(%r)\n" % (id, fn, ar))
self.fail(message) self.fail(message)
except OverflowError:
message = ("Unexpected OverflowError in " +
"test %s:%s(%r)\n" % (id, fn, ar))
self.fail(message)
self.ftest("%s:%s(%r)" % (id, fn, ar), result, er) self.ftest("%s:%s(%r)" % (id, fn, ar), result, er)
def test_main(): def test_main():