From c9c6f81bf67a5958fce7295596a6de007636cdc9 Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Sat, 13 Nov 2010 23:23:51 -0800 Subject: [PATCH] Exception propagation test. --- tests/run/exceptionpropagation.pyx | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/tests/run/exceptionpropagation.pyx b/tests/run/exceptionpropagation.pyx index 411d436b..a95c3a4c 100644 --- a/tests/run/exceptionpropagation.pyx +++ b/tests/run/exceptionpropagation.pyx @@ -28,3 +28,17 @@ def test_except_expr(bint fire): RuntimeError """ except_expr(fire) + +cdef double except_big_result(bint fire) except 100000000000000000000000000000000: + if fire: + raise RuntimeError + +def test_except_big_result(bint fire): + """ + >>> test_except_big_result(False) + >>> test_except_big_result(True) + Traceback (most recent call last): + ... + RuntimeError + """ + except_big_result(fire) -- 2.26.2