Commit 4d12bf8a authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Option to skip ways when running the testsuite

parent 568e6ebb
......@@ -26,6 +26,7 @@ long_options = [
"output-summary=", # file in which to save the (human-readable) summary
"only=", # just this test (can be give multiple --only= flags)
"way=", # just this way
"skipway=", # skip this way
"threads=", # threads to run simultaneously
]
......@@ -57,6 +58,15 @@ for opt,arg in opts:
config.run_ways = filter(eq(arg), config.run_ways + config.other_ways)
config.compile_ways = filter(eq(arg), config.compile_ways + config.other_ways)
if opt == '--skipway':
if (arg not in config.run_ways and arg not in config.compile_ways and arg not in config.other_ways):
sys.stderr.write("ERROR: requested way \'" +
arg + "\' does not exist\n")
sys.exit(1)
config.other_ways = filter(neq(arg), config.other_ways)
config.run_ways = filter(neq(arg), config.run_ways)
config.compile_ways = filter(neq(arg), config.compile_ways)
if opt == '--threads':
config.threads = int(arg)
......
......@@ -4,6 +4,9 @@
def eq(x):
return lambda y,z=x: y == z
def neq(x):
return lambda y,z=x: y != z
def append(x,y):
return x + y
......
......@@ -140,6 +140,7 @@ test: timeout
$(patsubst %, --only=%, $(TEST)) \
$(patsubst %, --only=%, $(TESTS)) \
$(patsubst %, --way=%, $(WAY)) \
$(patsubst %, --skipway=%, $(SKIPWAY)) \
$(setfast) \
$(setaccept)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment