Index: tools/run-tests.py |
diff --git a/tools/run-tests.py b/tools/run-tests.py |
index 761d03fe3351f4a15a46c3745d3561bc5abac86e..03722a5ca3caa29dbf222d31757e692760dcdf35 100755 |
--- a/tools/run-tests.py |
+++ b/tools/run-tests.py |
@@ -94,6 +94,9 @@ def BuildOptions(): |
default=False, action="store_true") |
result.add_option("--cat", help="Print the source of the tests", |
default=False, action="store_true") |
+ result.add_option("--classification", |
Jakob Kummerow
2013/08/06 11:11:01
"classification" is too generic. How about "--flak
|
+ help="Class of tests to run (all|flaky|non-flaky)", |
+ default="all") |
result.add_option("--command-prefix", |
help="Prepended to each shell command used to run a test", |
default="") |
@@ -204,6 +207,9 @@ def ProcessOptions(options): |
# This is OK for distributed running, so we don't need to set no_network. |
options.command_prefix = (["python", "-u", run_valgrind] + |
options.command_prefix) |
+ if not options.classification in ["all", "flaky", "non-flaky"]: |
+ print "Unknown classification %s" % options.classification |
+ return False |
return True |
@@ -315,7 +321,7 @@ def Execute(arch, mode, args, options, suites, workspace): |
if len(args) > 0: |
s.FilterTestCasesByArgs(args) |
all_tests += s.tests |
- s.FilterTestCasesByStatus(options.warn_unused) |
+ s.FilterTestCasesByStatus(options.warn_unused, options.classification) |
if options.cat: |
verbose.PrintTestSource(s.tests) |
continue |