[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] [thandy/master] fix "make test"



Author: Sebastian Hahn <sebastian@xxxxxxxxxxxxxx>
Date: Sat, 30 May 2009 04:04:24 +0200
Subject: fix "make test"
Commit: 8f402e0b6213f69d2dee426afeef2ca34db122ff

---
 Makefile            |    4 +++-
 lib/thandy/tests.py |    6 ++++--
 2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index c2268cb..58f019c 100644
--- a/Makefile
+++ b/Makefile
@@ -3,7 +3,9 @@ all:
 	python setup.py build
 
 test:
-	export PYTHONPATH=./lib/ && python -m thandy/tests
+	export PYTHONPATH=./lib/ && python -c "from thandy.tests import \
+	run_tests;\
+	    run_tests()"
 
 install:
 	python setup.py install
diff --git a/lib/thandy/tests.py b/lib/thandy/tests.py
index 1fbc4d6..a46258d 100644
--- a/lib/thandy/tests.py
+++ b/lib/thandy/tests.py
@@ -142,7 +142,9 @@ def suite():
 
     return suite
 
+def run_tests():
+    unittest.TextTestRunner(verbosity=1).run(suite())
 
 if __name__ == '__main__':
-
-    unittest.TextTestRunner(verbosity=1).run(suite())
+    run_tests()
+    
-- 
1.5.6.5