Commit 34456bb9 authored by Robert Bradshaw's avatar Robert Bradshaw

More gdb test guards.

parent 0d89c84c
......@@ -645,7 +645,11 @@ class CythonUnitTestCase(CythonCompileTestCase):
pass
include_debugger = sys.version_info[:2] > (2, 5)
try:
import gdb
include_debugger = sys.version_info[:2] > (2, 5)
except:
include_debugger = False
def collect_unittests(path, module_prefix, suite, selectors):
def file_matches(filename):
......@@ -703,8 +707,9 @@ def collect_doctests(path, module_prefix, suite, selectors):
filename in blacklist)
import doctest, types
for dirpath, dirnames, filenames in os.walk(path):
parentname = os.path.split(dirpath)[-1]
if package_matches(parentname):
for dir in list(dirnames):
if not package_matches(dir):
dirnames.remove(dir)
for f in filenames:
if file_matches(f):
if not f.endswith('.py'): continue
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment