summaryrefslogtreecommitdiff
path: root/testsuite/driver/runtests.py
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2020-02-24 11:21:14 -0500
committerMarge Bot <ben+marge-bot@smart-cactus.org>2020-02-26 15:10:09 -0500
commit7dc54873c0768ad3234c40300ae20e4f1e847bdd (patch)
tree8f097cd24106bb68744c7e0bfb8e5e4e2f0fd48e /testsuite/driver/runtests.py
parentc7d4fa55d19f7ac72f3071f9d19e03443c9b538c (diff)
downloadhaskell-7dc54873c0768ad3234c40300ae20e4f1e847bdd.tar.gz
testsuite: Allow tests to be marked as broken on the command line
This allows us to work-around distribution-specific breakage easily.
Diffstat (limited to 'testsuite/driver/runtests.py')
-rw-r--r--testsuite/driver/runtests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/testsuite/driver/runtests.py b/testsuite/driver/runtests.py
index 9eed68bc37..e587a1150d 100644
--- a/testsuite/driver/runtests.py
+++ b/testsuite/driver/runtests.py
@@ -26,6 +26,7 @@ import subprocess
from testutil import getStdout, Watcher, str_warn, str_info
from testglobals import getConfig, ghc_env, getTestRun, TestConfig, \
TestOptions, brokens, PerfMetric
+from my_typing import TestName
from perf_notes import MetricChange, inside_git_repo, is_worktree_dirty, format_perf_stat
from junit import junit
import term_color
@@ -67,6 +68,7 @@ parser.add_argument("--skipway", action="append", help="skip this way")
parser.add_argument("--threads", type=int, help="threads to run simultaneously")
parser.add_argument("--verbose", type=int, choices=[0,1,2,3,4,5], help="verbose (Values 0 through 5 accepted)")
parser.add_argument("--junit", type=argparse.FileType('wb'), help="output testsuite summary in JUnit format")
+parser.add_argument("--broken-test", action="append", default=[], help="a test name to mark as broken for this run")
parser.add_argument("--test-env", default='local', help="Override default chosen test-env.")
perf_group.add_argument("--skip-perf-tests", action="store_true", help="skip performance tests")
perf_group.add_argument("--only-perf-tests", action="store_true", help="Only do performance tests")
@@ -123,6 +125,8 @@ if args.skipway:
config.run_ways = [w for w in config.run_ways if w not in args.skipway]
config.compile_ways = [w for w in config.compile_ways if w not in args.skipway]
+config.broken_tests |= {TestName(t) for t in args.broken_test}
+
if args.threads:
config.threads = args.threads
config.use_threads = True