about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2009-12-11 23:35:26 +0100
committerhut <hut@lavabit.com>2009-12-11 23:35:26 +0100
commit084a0743189363c8c03aae1fe6766ae92a4469a3 (patch)
tree2bc35c333b5e6d6c53a25a28d65de60e0f3502c5
parent4b66c3a834409458c0bf665b1f6065c1aab3ba8d (diff)
downloadranger-084a0743189363c8c03aae1fe6766ae92a4469a3.tar.gz
run all tests with a single executable
-rwxr-xr-xall_tests.py11
-rw-r--r--test/__init__.py5
2 files changed, 16 insertions, 0 deletions
diff --git a/all_tests.py b/all_tests.py
new file mode 100755
index 00000000..b408b5de
--- /dev/null
+++ b/all_tests.py
@@ -0,0 +1,11 @@
+#!/usr/bin/python3
+import unittest
+from test import *
+
+tests = []
+for key, val in vars().copy().items():
+	if key.startswith('tc_'):
+		tests.extend(v for k,v in vars(val).items() if type(v) == type)
+
+suite = unittest.TestSuite(map(unittest.makeSuite, tests))
+unittest.TextTestRunner(verbosity=2).run(suite)
diff --git a/test/__init__.py b/test/__init__.py
index e69de29b..4f1c736a 100644
--- a/test/__init__.py
+++ b/test/__init__.py
@@ -0,0 +1,5 @@
+import os, sys
+
+__all__ = [ x[0:x.index('.')] \
+		for x in os.listdir(os.path.dirname(__file__)) \
+		if x.startswith('tc_') ]
specs/ranger/commit/doc/colorschemes.txt?h=v1.0.4&id=efdc7b16e9f422f2d95271e6d4bf64dd9a03ea33'>efdc7b16 ^
a8f9cf2c ^

efdc7b16 ^














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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101