@@ -57,7 +57,11 @@ GENERAL OPTIONS
57
57
58
58
.. option :: -h , --help
59
59
60
- Show the :program: `lit ` help message.
60
+ Show the :program: `lit ` help message and exit.
61
+
62
+ .. option :: --version
63
+
64
+ Show :program: `lit `'s version number and exit.
61
65
62
66
.. option :: -j N , --workers=N
63
67
@@ -108,23 +112,51 @@ OUTPUT OPTIONS
108
112
109
113
Enable -v, but for all tests not just failed tests.
110
114
115
+ .. option :: -o PATH , --output PATH
116
+
117
+ Write test results to the provided path.
118
+
111
119
.. option :: --no-progress-bar
112
120
113
121
Do not use curses based progress bar.
114
122
123
+ .. option :: --show-excluded
124
+
125
+ Show excluded tests.
126
+
127
+ .. option :: --show-skipped
128
+
129
+ Show skipped tests.
130
+
115
131
.. option :: --show-unsupported
116
132
117
- Show the names of unsupported tests.
133
+ Show unsupported tests.
134
+
135
+ .. option :: --show-pass
136
+
137
+ Show passed tests.
138
+
139
+ .. option :: --show-flakypass
140
+
141
+ Show passed with retry tests.
118
142
119
143
.. option :: --show-xfail
120
144
121
- Show the names of tests that were expected to fail .
145
+ Show expectedly failed tests.
122
146
123
147
.. _execution-options :
124
148
125
149
EXECUTION OPTIONS
126
150
-----------------
127
151
152
+ .. option :: --gtest-sharding
153
+
154
+ Enable sharding for GoogleTest format.
155
+
156
+ .. option :: --no-gtest-sharding
157
+
158
+ Disable sharding for GoogleTest format.
159
+
128
160
.. option :: --path=PATH
129
161
130
162
Specify an additional ``PATH `` to use when searching for executables in tests.
@@ -139,32 +171,73 @@ EXECUTION OPTIONS
139
171
"``valgrind ``" feature that can be used to conditionally disable (or expect
140
172
failure in) certain tests.
141
173
142
- .. option :: --vg-arg=ARG
143
-
144
- When :option: `--vg ` is used, specify an additional argument to pass to
145
- :program: `valgrind ` itself.
146
-
147
174
.. option :: --vg-leak
148
175
149
176
When :option: `--vg ` is used, enable memory leak checks. When this option is
150
177
enabled, :program: `lit ` will also automatically provide a "``vg_leak ``"
151
178
feature that can be used to conditionally disable (or expect failure in)
152
179
certain tests.
153
180
181
+ .. option :: --vg-arg=ARG
182
+
183
+ When :option: `--vg ` is used, specify an additional argument to pass to
184
+ :program: `valgrind ` itself.
185
+
186
+ .. option :: --no-execute
187
+
188
+ Don't execute any tests (assume that they pass).
189
+
190
+ .. option :: --xunit-xml-output XUNIT_XML_OUTPUT
191
+
192
+ Write XUnit-compatible XML test reports to the specified file.
193
+
194
+ .. option :: --resultdb-output RESULTDB_OUTPUT
195
+
196
+ Write LuCI ResultDB compatible JSON to the specified file.
197
+
198
+ .. option :: --time-trace-output TIME_TRACE_OUTPUT
199
+
200
+ Write Chrome tracing compatible JSON to the specified file
201
+
202
+ .. option :: --timeout MAXINDIVIDUALTESTTIME
203
+
204
+ Maximum time to spend running a single test (in seconds). 0 means no time
205
+ limit. [Default: 0]
206
+
207
+ .. option :: --timeout=N
208
+
209
+ Spend at most ``N `` seconds (approximately) running each individual test.
210
+ ``0 `` means no time limit, and ``0 `` is the default. Note that this is not an
211
+ alias for :option: `--max-time `; the two are different kinds of maximums.
212
+
213
+ .. option :: --max-failures MAX_FAILURES
214
+
215
+ Stop execution after the given number of failures.
216
+
217
+ .. option :: --allow-empty-runs
218
+
219
+ Do not fail the run if all tests are filtered out.
220
+
221
+ .. option :: --per-test-coverage
222
+
223
+ Emit the necessary test coverage data, divided per test case (involves
224
+ setting a unique value to LLVM_PROFILE_FILE for each RUN). The coverage
225
+ data files will be emitted in the directory specified by ``config.test_exec_root ``.
226
+
227
+ .. option :: --ignore-fail
228
+
229
+ Exit with status zero even if some tests fail.
230
+
154
231
.. option :: --skip-test-time-recording
155
232
156
- Disable tracking the wall time individual tests take to execute .
233
+ Do not track elapsed wall time for each test .
157
234
158
235
.. option :: --time-tests
159
236
160
237
Track the wall time individual tests take to execute and includes the results
161
238
in the summary output. This is useful for determining which tests in a test
162
239
suite take the most time to execute.
163
240
164
- .. option :: --ignore-fail
165
-
166
- Exit with status zero even if some tests fail.
167
-
168
241
.. _selection-options :
169
242
170
243
SELECTION OPTIONS
@@ -178,23 +251,6 @@ The timing data is stored in the `test_exec_root` in a file named
178
251
`.lit_test_times.txt `. If this file does not exist, then `lit ` checks the
179
252
`test_source_root ` for the file to optionally accelerate clean builds.
180
253
181
- .. option :: --shuffle
182
-
183
- Run the tests in a random order, not failing/slowest first. Deprecated,
184
- use :option: `--order ` instead.
185
-
186
- .. option :: --per-test-coverage
187
-
188
- Emit the necessary test coverage data, divided per test case (involves
189
- setting a unique value to LLVM_PROFILE_FILE for each RUN). The coverage
190
- data files will be emitted in the directory specified by `config.test_exec_root `.
191
-
192
- .. option :: --max-failures N
193
-
194
- Stop execution after the given number ``N `` of failures.
195
- An integer argument should be passed on the command line
196
- prior to execution.
197
-
198
254
.. option :: --max-tests=N
199
255
200
256
Run at most ``N `` tests and then terminate.
@@ -205,16 +261,6 @@ The timing data is stored in the `test_exec_root` in a file named
205
261
Note that this is not an alias for :option: `--timeout `; the two are
206
262
different kinds of maximums.
207
263
208
- .. option :: --num-shards=M
209
-
210
- Divide the set of selected tests into ``M `` equal-sized subsets or
211
- "shards", and run only one of them. Must be used with the
212
- ``--run-shard=N `` option, which selects the shard to run. The environment
213
- variable ``LIT_NUM_SHARDS `` can also be used in place of this
214
- option. These two options provide a coarse mechanism for partitioning large
215
- testsuites, for parallel execution on separate machines (say in a large
216
- testing farm).
217
-
218
264
.. option :: --order={lexical ,random ,smart}
219
265
220
266
Define the order in which tests are run. The supported values are:
@@ -228,18 +274,14 @@ The timing data is stored in the `test_exec_root` in a file named
228
274
tests, all in descending execution time order. This is the default as it
229
275
optimizes concurrency.
230
276
231
- .. option :: --run-shard=N
277
+ .. option :: --shuffle
232
278
233
- Select which shard to run, assuming the ``--num-shards=M `` option was
234
- provided. The two options must be used together, and the value of ``N ``
235
- must be in the range ``1..M ``. The environment variable
236
- ``LIT_RUN_SHARD `` can also be used in place of this option.
279
+ Run the tests in a random order, not failing/slowest first. Deprecated,
280
+ use :option: `--order ` instead.
237
281
238
- .. option :: --timeout=N
282
+ .. option :: -i , --incremental
239
283
240
- Spend at most ``N `` seconds (approximately) running each individual test.
241
- ``0 `` means no time limit, and ``0 `` is the default. Note that this is not an
242
- alias for :option: `--max-time `; the two are different kinds of maximums.
284
+ Run failed tests first (DEPRECATED: use ``--order=smart ``).
243
285
244
286
.. option :: --filter=REGEXP
245
287
@@ -297,6 +339,23 @@ The timing data is stored in the `test_exec_root` in a file named
297
339
primary purpose is to suppress an ``XPASS `` result without modifying a test
298
340
case that uses the ``XFAIL `` directive.
299
341
342
+ .. option :: --num-shards=M
343
+
344
+ Divide the set of selected tests into ``M `` equal-sized subsets or
345
+ "shards", and run only one of them. Must be used with the
346
+ ``--run-shard=N `` option, which selects the shard to run. The environment
347
+ variable ``LIT_NUM_SHARDS `` can also be used in place of this
348
+ option. These two options provide a coarse mechanism for partitioning large
349
+ testsuites, for parallel execution on separate machines (say in a large
350
+ testing farm).
351
+
352
+ .. option :: --run-shard=N
353
+
354
+ Select which shard to run, assuming the ``--num-shards=M `` option was
355
+ provided. The two options must be used together, and the value of ``N ``
356
+ must be in the range ``1..M ``. The environment variable
357
+ ``LIT_RUN_SHARD `` can also be used in place of this option.
358
+
300
359
ADDITIONAL OPTIONS
301
360
------------------
302
361
@@ -313,6 +372,11 @@ ADDITIONAL OPTIONS
313
372
314
373
List all of the discovered tests and exit.
315
374
375
+ .. option :: --show-used-features
376
+
377
+ Show all features used in the test suite (in ``XFAIL ``, ``UNSUPPORTED `` and
378
+ ``REQUIRES ``) and exit.
379
+
316
380
EXIT STATUS
317
381
-----------
318
382
0 commit comments