blob: 253bb19ccd070e30296f40139fc8ba37d18138ef (
plain)
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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
|
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"DTD/xhtml1-strict.dtd">
<html>
<head>
<title>testtools.run : API documentation</title>
<meta content="text/html;charset=utf-8" http-equiv="Content-Type" />
<link href="bootstrap.min.css" type="text/css" rel="stylesheet" />
<link href="apidocs.css" type="text/css" rel="stylesheet" />
</head>
<body>
<nav class="navbar navbar-default">
<div class="container">
<div class="navbar-header">
<a href="index.html" class="navbar-brand">
<a href="https://github.com/testing-cabal/testtools">testtools</a> API Documentation
</a>
</div>
</div>
</nav>
<div class="container">
<div class="page-header">
<h1 class="module"><code>testtools.run</code> <small>module documentation</small></h1>
<span id="partOf">
Part of <code><a href="testtools.html" class="code">testtools</a></code>
</span>
</div>
<div class="extrasDocstring">
</div>
<div class="moduleDocstring">
<div><p>python -m testtools.run testspec [testspec...]</p>
<p>Run some tests with the testtools extended API.</p>
<dl class="rst-docutils">
<dt>For instance, to run the testtools test suite.</dt>
<dd>$ python -m testtools.run testtools.tests.test_suite</dd>
</dl><table class="fieldTable"></table></div>
</div>
<div id="splitTables">
<table class="children sortable" id="id159">
<tr class="function">
<td>Function</td>
<td><a href="testtools.run.html#list_test" class="code">list_test</a></td>
<td><span>Return the test ids that would be run if test() was run.</span></td>
</tr><tr class="class">
<td>Class</td>
<td><a href="testtools.run.TestToolsTestRunner.html" class="code">TestToolsTestRunner</a></td>
<td><span>A thunk object to support unittest.TestProgram.</span></td>
</tr><tr class="class">
<td>Class</td>
<td><a href="testtools.run.TestProgram.html" class="code">TestProgram</a></td>
<td><span>A command-line program that runs a set of tests; this is primarily for making test modules conveniently executable.</span></td>
</tr><tr class="function">
<td>Function</td>
<td><a href="testtools.run.html#main" class="code">main</a></td>
<td><span class="undocumented">Undocumented</span></td>
</tr>
</table>
</div>
<div id="childList">
<div class="function">
<a name="testtools.run.list_test">
</a>
<a name="list_test">
</a>
<div class="functionHeader">
def
list_test(test):
</div>
<div class="docstring functionBody">
<div><p>Return the test ids that would be run if test() was run.</p>
<p>When things fail to import they can be represented as well, though
we use an ugly hack (see <a href="http://bugs.python.org/issue19746" class="rst-reference external" target="_top">http://bugs.python.org/issue19746</a> for details)
to determine that. The difference matters because if a user is
filtering tests to run on the returned ids, a failed import can reduce
the visible tests but it can be impossible to tell that the selected
test would have been one of the imported ones.</p><table class="fieldTable"><tr class="fieldStart"><td class="fieldName">Returns</td><td colspan="2">A tuple of test ids that would run and error strings
describing things that failed to import.</td></tr></table></div>
</div>
</div><div class="function">
<a name="testtools.run.main">
</a>
<a name="main">
</a>
<div class="functionHeader">
def
main(argv, stdout):
</div>
<div class="docstring functionBody">
<div class="undocumented">Undocumented</div>
</div>
</div>
</div>
<address>
<a href="index.html">API Documentation</a> for <a href="https://github.com/testing-cabal/testtools">testtools</a>, generated by <a href="https://github.com/twisted/pydoctor/">pydoctor</a> at 2015-07-01 16:11:28.
</address>
</div>
</body>
</html>
|