Commit 447791f5 authored by Robert Bradshaw's avatar Robert Bradshaw

cleanup

parent 76f1228e
...@@ -63,11 +63,9 @@ if sys.platform == 'win32': ...@@ -63,11 +63,9 @@ if sys.platform == 'win32':
except ValueError: pass except ValueError: pass
distutils_distro.parse_config_files(cfgfiles) distutils_distro.parse_config_files(cfgfiles)
TEST_DIRS = ['compile', 'errors', 'run', 'wrappers', 'pyregr', 'build']
TEST_RUN_DIRS = ['run', 'wrappers', 'pyregr']
# Lists external modules, and a matcher matching tests # Lists external modules, and a matcher matching tests
# which should be excluded if the module is not present. # which should be excluded if the module is not present.
# TODO: use tags for these
EXT_DEP_MODULES = { EXT_DEP_MODULES = {
'numpy' : re.compile('.*\.numpy_.*').match, 'numpy' : re.compile('.*\.numpy_.*').match,
'pstats' : re.compile('.*\.pstats_.*').match, 'pstats' : re.compile('.*\.pstats_.*').match,
...@@ -79,8 +77,6 @@ def get_numpy_include_dirs(): ...@@ -79,8 +77,6 @@ def get_numpy_include_dirs():
return [numpy.get_include()] return [numpy.get_include()]
# TODO: use tags for these
EXT_DEP_INCLUDES = [ EXT_DEP_INCLUDES = [
# test name matcher , callable returning list # test name matcher , callable returning list
(re.compile('numpy_.*').match, get_numpy_include_dirs), (re.compile('numpy_.*').match, get_numpy_include_dirs),
...@@ -209,12 +205,11 @@ class TestBuilder(object): ...@@ -209,12 +205,11 @@ class TestBuilder(object):
def build_suite(self): def build_suite(self):
suite = unittest.TestSuite() suite = unittest.TestSuite()
test_dirs = TEST_DIRS
filenames = os.listdir(self.rootdir) filenames = os.listdir(self.rootdir)
filenames.sort() filenames.sort()
for filename in filenames: for filename in filenames:
path = os.path.join(self.rootdir, filename) path = os.path.join(self.rootdir, filename)
if os.path.isdir(path) and filename in test_dirs: if os.path.isdir(path):
if filename == 'pyregr' and not self.with_pyregr: if filename == 'pyregr' and not self.with_pyregr:
continue continue
suite.addTest( suite.addTest(
......
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