summaryrefslogtreecommitdiff
path: root/test/test.py
diff options
context:
space:
mode:
authorjvoisin2011-12-25 18:21:59 +0100
committerjvoisin2011-12-25 18:21:59 +0100
commita4f271f55c0739224bd32818432a59bf08b16288 (patch)
treee3f4d64b8fbec01e5e41db221ba5f93ada066327 /test/test.py
parentae1169016f6ea82631227a9d0cb42af291a9ae18 (diff)
Improve modularity for testsuite
The test.py file now launch all testsuites. All testsuites now have a main() function
Diffstat (limited to 'test/test.py')
-rw-r--r--test/test.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/test.py b/test/test.py
index c414c77..9b440ca 100644
--- a/test/test.py
+++ b/test/test.py
@@ -11,6 +11,7 @@ import glob
11import tempfile 11import tempfile
12import unittest 12import unittest
13import subprocess 13import subprocess
14import sys
14 15
15VERBOSITY = 3 16VERBOSITY = 3
16 17
@@ -60,3 +61,19 @@ class MATTest(unittest.TestCase):
60 Remove the tmp folder 61 Remove the tmp folder
61 ''' 62 '''
62 shutil.rmtree(self.tmpdir) 63 shutil.rmtree(self.tmpdir)
64
65def main():
66 import clitest
67 import libtest
68
69 failed_tests = 0
70
71 print('Running cli related tests:\n')
72 failed_tests += clitest.main()
73 print('\nRunning library related tests:\n')
74 failed_tests += libtest.main()
75 print('\nTotal failed tests: ' + str(failed_tests))
76 return failed_tests
77
78if __name__ == '__main__':
79 sys.exit(main())