summaryrefslogtreecommitdiffstats
path: root/python/tests/tests.py
diff options
context:
space:
mode:
authorFrederic Peters <fpeters@entrouvert.com>2004-07-25 12:43:57 +0000
committerFrederic Peters <fpeters@entrouvert.com>2004-07-25 12:43:57 +0000
commitb40a7c6a9f28903bf9972bcf1e562e55fc688617 (patch)
treebaa638badd0c24a56d5753f20bfbde133da96fd4 /python/tests/tests.py
parent03d61844cddff31ee00b1f5847276f9ba9a488fd (diff)
downloadlasso-b40a7c6a9f28903bf9972bcf1e562e55fc688617.tar.gz
lasso-b40a7c6a9f28903bf9972bcf1e562e55fc688617.tar.xz
lasso-b40a7c6a9f28903bf9972bcf1e562e55fc688617.zip
nozero exit code if a test failed
Diffstat (limited to 'python/tests/tests.py')
-rwxr-xr-xpython/tests/tests.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/python/tests/tests.py b/python/tests/tests.py
index de359ee5..644135eb 100755
--- a/python/tests/tests.py
+++ b/python/tests/tests.py
@@ -38,6 +38,7 @@ testSuites = (
'login_tests',
)
+success = True
for testSuite in testSuites:
fp, pathname, description = imp.find_module(testSuite)
try:
@@ -58,5 +59,8 @@ for testSuite in testSuites:
print doc
print '-' * len(doc)
- unittest.TextTestRunner(verbosity=2).run(module.allTests)
+ result = unittest.TextTestRunner(verbosity=2).run(module.allTests)
+ success = success and result.wasSuccessful()
+
+sys.exit(not success)