[pypy-svn] rev 576 - pypy/trunk/src/pypy
mwh at codespeak.net
mwh at codespeak.net
Tue May 27 16:48:32 CEST 2003
Author: mwh
Date: Tue May 27 16:48:32 2003
New Revision: 576
Modified:
pypy/trunk/src/pypy/testall.py
Log:
add --noappspace option -- appspace isn't changing much at the moment
& the tests take ages.
Modified: pypy/trunk/src/pypy/testall.py
==============================================================================
--- pypy/trunk/src/pypy/testall.py (original)
+++ pypy/trunk/src/pypy/testall.py Tue May 27 16:48:32 2003
@@ -16,10 +16,11 @@
sys.path.insert(0, PYPYDIR)
break
-def find_tests(root):
+def find_tests(root, no_appspace=0):
testmods = []
def callback(arg, dirname, names):
- if os.path.basename(dirname) == 'test':
+ if ( os.path.basename(dirname) == 'test'
+ and ((not no_appspace) or dirname.find('appspace') == -1) ):
package = dirname[len(PYPYDIR)+1:].replace(os.sep, '.')
testfiles = [f[:-3] for f in names
if f.startswith('test_') and f.endswith('.py')]
@@ -32,8 +33,11 @@
return tl.loadTestsFromNames(testmods)
-if __name__ == '__main__':
+def main(argv=None):
+ if argv is None:
+ argv = sys.argv
runner = unittest.TextTestRunner()
- runner.run(find_tests(PYPYDIR))
-
+ runner.run(find_tests(PYPYDIR, '--noappspace' in sys.argv))
+if __name__ == '__main__':
+ main()
More information about the Pypy-commit
mailing list