From e5635f4ab3d0fd00dd3951865fea82003205dae1 Mon Sep 17 00:00:00 2001 From: Damien George Date: Thu, 1 Oct 2015 22:48:48 +0100 Subject: py: Catch all cases of integer (big and small) division by zero. --- tests/float/int_big_float.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tests/float') diff --git a/tests/float/int_big_float.py b/tests/float/int_big_float.py index 2c404189c..b1a26ca73 100644 --- a/tests/float/int_big_float.py +++ b/tests/float/int_big_float.py @@ -17,3 +17,8 @@ print("%.5g" % (i / 1.2)) # this should delegate to complex print("%.5g" % (i * 1.2j).imag) + +try: + i / 0 +except ZeroDivisionError: + print("ZeroDivisionError") -- cgit v1.2.3