From: Robert Bradshaw Date: Sun, 14 Nov 2010 07:23:51 +0000 (-0800) Subject: Exception propagation test. X-Git-Tag: 0.14.alpha0~156 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=c9c6f81bf67a5958fce7295596a6de007636cdc9;p=cython.git Exception propagation test. --- 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)