summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2019-04-07 01:50:24 (GMT)
committerBen Gamari <ben@smart-cactus.org>2019-06-12 12:20:25 (GMT)
commit55b5bb14b9a2487bab80411776ae34c143eddb1a (patch)
tree4e7c8aa223832e7f9004c4863094505b4c32c91e
parent329dcd7a59e7d46cb5110e1dfb9f8b7f50f0e3a2 (diff)
downloadghc-55b5bb14b9a2487bab80411776ae34c143eddb1a.zip
ghc-55b5bb14b9a2487bab80411776ae34c143eddb1a.tar.gz
ghc-55b5bb14b9a2487bab80411776ae34c143eddb1a.tar.bz2
testsuite: Fix omit_ways usage
omit_ways expects a list but this was broken in several cases.
-rw-r--r--testsuite/driver/testlib.py1
-rw-r--r--testsuite/tests/concurrent/should_run/all.T2
-rw-r--r--testsuite/tests/lib/integer/all.T4
-rw-r--r--testsuite/tests/programs/barton-mangler-bug/test.T2
-rw-r--r--testsuite/tests/rts/all.T2
-rwxr-xr-xtestsuite/tests/typecheck/should_run/all.T2
-rw-r--r--testsuite/tests/utils/should_run/all.T2
7 files changed, 8 insertions, 7 deletions
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py
index 7284b80..442d90d 100644
--- a/testsuite/driver/testlib.py
+++ b/testsuite/driver/testlib.py
@@ -274,6 +274,7 @@ def omit_ways( ways ):
return lambda name, opts, w=ways: _omit_ways( name, opts, w )
def _omit_ways( name, opts, ways ):
+ assert ways.__class__ is list
opts.omit_ways += ways
# -----
diff --git a/testsuite/tests/concurrent/should_run/all.T b/testsuite/tests/concurrent/should_run/all.T
index 4e60a1d..10d8424 100644
--- a/testsuite/tests/concurrent/should_run/all.T
+++ b/testsuite/tests/concurrent/should_run/all.T
@@ -239,7 +239,7 @@ test('conc067', ignore_stdout, compile_and_run, [''])
# omit threaded2, the behaviour of this test is non-deterministic with more
# than one CPU.
-test('conc068', [ omit_ways('threaded2'), exit_code(1) ], compile_and_run, [''])
+test('conc068', [ omit_ways(['threaded2']), exit_code(1) ], compile_and_run, [''])
test('setnumcapabilities001',
[ only_ways(['threaded1','threaded2']),
diff --git a/testsuite/tests/lib/integer/all.T b/testsuite/tests/lib/integer/all.T
index 5e629b9..97065a3 100644
--- a/testsuite/tests/lib/integer/all.T
+++ b/testsuite/tests/lib/integer/all.T
@@ -1,8 +1,8 @@
test('integerBits', normal, compile_and_run, [''])
test('integerConversions', normal, compile_and_run, [''])
# skip ghci as it doesn't support unboxed tuples
-test('integerGmpInternals', [reqlib('integer-gmp'), omit_ways('ghci')], compile_and_run, [''])
-test('plusMinusInteger', [omit_ways('ghci')], compile_and_run, [''])
+test('integerGmpInternals', [reqlib('integer-gmp'), omit_ways(['ghci'])], compile_and_run, [''])
+test('plusMinusInteger', [omit_ways(['ghci'])], compile_and_run, [''])
test('integerConstantFolding', normal, makefile_test, ['integerConstantFolding'])
test('fromToInteger', [], makefile_test, ['fromToInteger'])
test('IntegerConversionRules', [], makefile_test, ['IntegerConversionRules'])
diff --git a/testsuite/tests/programs/barton-mangler-bug/test.T b/testsuite/tests/programs/barton-mangler-bug/test.T
index dcccf8e..8258106 100644
--- a/testsuite/tests/programs/barton-mangler-bug/test.T
+++ b/testsuite/tests/programs/barton-mangler-bug/test.T
@@ -8,7 +8,7 @@ test('barton-mangler-bug',
'Plot.hi', 'Plot.o',
'PlotExample.hi', 'PlotExample.o',
'TypesettingTricks.hi', 'TypesettingTricks.o']),
- omit_ways('debug') # Fails for debug way due to annotation linting timeout
+ omit_ways(['debug']) # Fails for debug way due to annotation linting timeout
],
multimod_compile_and_run, ['Main', ''])
diff --git a/testsuite/tests/rts/all.T b/testsuite/tests/rts/all.T
index 3c7afc0..173ed7c 100644
--- a/testsuite/tests/rts/all.T
+++ b/testsuite/tests/rts/all.T
@@ -93,7 +93,7 @@ test('stack002', [extra_files(['stack001.hs']),
# run this test with very small stack chunks to exercise the stack
# overflow/underflow machinery.
-test('stack003', [ omit_ways('ghci'), # uses unboxed tuples
+test('stack003', [ omit_ways(['ghci']), # uses unboxed tuples
extra_run_opts('500000 +RTS -kc1k -kb100 -K96m -RTS') ],
compile_and_run, [''])
diff --git a/testsuite/tests/typecheck/should_run/all.T b/testsuite/tests/typecheck/should_run/all.T
index 54d5ae4..598d467 100755
--- a/testsuite/tests/typecheck/should_run/all.T
+++ b/testsuite/tests/typecheck/should_run/all.T
@@ -96,7 +96,7 @@ test('T6117', normal, compile_and_run, [''])
test('T5751', normal, compile_and_run, [''])
test('T5913', normal, compile_and_run, [''])
test('T7748', normal, compile_and_run, [''])
-test('T7861', [omit_ways('debug'), exit_code(1)], compile_and_run, [''])
+test('T7861', [omit_ways(['debug']), exit_code(1)], compile_and_run, [''])
test('TcTypeNatSimpleRun', normal, compile_and_run, [''])
test('TcTypeSymbolSimpleRun', normal, compile_and_run, [''])
test('T8119', normal, ghci_script, ['T8119.script'])
diff --git a/testsuite/tests/utils/should_run/all.T b/testsuite/tests/utils/should_run/all.T
index 8817118..e2ae0f9 100644
--- a/testsuite/tests/utils/should_run/all.T
+++ b/testsuite/tests/utils/should_run/all.T
@@ -1,6 +1,6 @@
test('T14854',
[only_ways(threaded_ways),
- omit_ways('ghci'),
+ omit_ways(['ghci']),
reqlib('random'),
ignore_stderr],
compile_and_run,