projects
/
cython.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
38bc283
)
only consider packages when searching for unit tests
author
Stefan Behnel
<scoder@users.berlios.de>
Mon, 28 Jul 2008 19:02:29 +0000
(21:02 +0200)
committer
Stefan Behnel
<scoder@users.berlios.de>
Mon, 28 Jul 2008 19:02:29 +0000
(21:02 +0200)
runtests.py
patch
|
blob
|
history
diff --git
a/runtests.py
b/runtests.py
index 5310dd7a7eeaa3755adf98183c7d0dfed93ba9ea..bb5487a572db8cdee8fd2f63494a6a77de703eed 100644
(file)
--- a/
runtests.py
+++ b/
runtests.py
@@
-287,7
+287,18
@@
def collect_unittests(path, suite, selectors):
loader = unittest.TestLoader()
+ skipped_dirs = []
+
for dirpath, dirnames, filenames in os.walk(path):
+ if dirpath != path and "__init__.py" not in filenames:
+ skipped_dirs.append(dirpath + os.path.sep)
+ continue
+ skip = False
+ for dir in skipped_dirs:
+ if dirpath.startswith(dir):
+ skip = True
+ if skip:
+ continue
parentname = os.path.split(dirpath)[-1]
if package_matches(parentname):
for f in filenames: