From d79982c1b383242514a145e6de30a21f790c39d9 Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Sat, 17 Oct 2009 23:29:50 +0200 Subject: [PATCH] Py2 test fixes --- tests/run/funcexc_iter_T228.pyx | 2 ++ tests/run/funcexceptraise.pyx | 2 ++ 2 files changed, 4 insertions(+) diff --git a/tests/run/funcexc_iter_T228.pyx b/tests/run/funcexc_iter_T228.pyx index b3355b42..0fa6563e 100644 --- a/tests/run/funcexc_iter_T228.pyx +++ b/tests/run/funcexc_iter_T228.pyx @@ -45,6 +45,8 @@ True """ import sys +if sys.version_info[0] < 3: + sys.exc_clear() cdef class cy_iterator(object): def __iter__(self): diff --git a/tests/run/funcexceptraise.pyx b/tests/run/funcexceptraise.pyx index 900eee04..669022fc 100644 --- a/tests/run/funcexceptraise.pyx +++ b/tests/run/funcexceptraise.pyx @@ -11,6 +11,8 @@ __doc__ = u""" """ import sys +if sys.version_info[0] < 3: + sys.exc_clear() def foo(): try: -- 2.26.2