-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathrun.py
More file actions
38 lines (31 loc) · 1.19 KB
/
run.py
File metadata and controls
38 lines (31 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
from __future__ import unicode_literals
from __future__ import print_function
from __future__ import division
from __future__ import absolute_import
from future import standard_library
standard_library.install_aliases()
from builtins import *
from test.document.test_document import DocumentTest
from test.document.test_document_creator import DocumentCreatorTest
from test.document.test_document_with_tags import DocumentTagsTest
from test.document.test_documentmutation import DocumentMutationTest
from test.query_test.test_query import QueryTest
try:
import unittest2 as unittest
except ImportError:
import unittest
if __name__ == '__main__':
test_classes_to_run = [DocumentTest,
DocumentTagsTest,
QueryTest,
DocumentCreatorTest,
DocumentMutationTest
]
loader = unittest.TestLoader()
suites_list = []
for test_class in test_classes_to_run:
suite = loader.loadTestsFromTestCase(test_class)
suites_list.append(suite)
big_suite = unittest.TestSuite(suites_list)
runner = unittest.TextTestRunner()
results = runner.run(big_suite)