Commit 513a449c authored by Ben Gamari's avatar Ben Gamari 🐢
Browse files

testsuite: Use makefile_test

This eliminates most uses of run_command in the testsuite in favor of the more
structured makefile_test.
parent bdb559a6
test('recomp003', [extra_files(['A.hs'])], run_command, ['$MAKE -s --no-print-directory recomp003'])
test('recomp003', [extra_files(['A.hs'])],
makefile_test, [])
test('recomp004', [extra_files(['Main.hs', 'c.h', 'c1.c', 'c2.c'])], run_command, ['$MAKE -s --no-print-directory recomp004'])
test('recomp004', [extra_files(['Main.hs', 'c.h', 'c1.c', 'c2.c'])],
makefile_test, [])
test('recomp005', [extra_files(['A.hs', 'B.hs', 'C1.hs', 'C2.hs', 'D.hs', 'E.hs']),
when(fast(), skip)], run_command,
['$MAKE -s --no-print-directory recomp005'])
test('recomp005',
[extra_files(['A.hs', 'B.hs', 'C1.hs', 'C2.hs', 'D.hs', 'E.hs']),
when(fast(), skip)],
makefile_test, [])
test('recomp006', [extra_files(['A.hs', 'B1.hs', 'B2.hs']),
when(fast(), skip)], run_command,
['$MAKE -s --no-print-directory recomp006'])
when(fast(), skip)],
makefile_test, [])
......@@ -3,5 +3,5 @@
# "Fix a recompilation checking bug when a package dependency changes"
test('recomp007', [extra_files(['Setup.hs', 'a1/', 'a2/', 'b/']),
when(fast(), skip), normalise_slashes], run_command,
['$MAKE -s --no-print-directory recomp007'])
when(fast(), skip), normalise_slashes],
makefile_test, [])
# Test for #4469, a recompilation bug related to instances
test('recomp008', [extra_files(['A1.hs', 'A2.hs', 'B.hs', 'Main.hs']),
when(fast(), skip), normalise_slashes], run_command,
['$MAKE -s --no-print-directory recomp008'])
test('recomp008',
[extra_files(['A1.hs', 'A2.hs', 'B.hs', 'Main.hs']),
when(fast(), skip), normalise_slashes],
makefile_test, [])
# Test for #481, a recompilation bug with Template Haskell
test('recomp009', [extra_files(['Main.hs', 'Sub1.hs', 'Sub2.hs'])], run_command, ['$MAKE -s --no-print-directory recomp009'])
test('recomp009', [extra_files(['Main.hs', 'Sub1.hs', 'Sub2.hs'])], makefile_test, [])
# Test for #5614, a recompilation bug
test('recomp010', [extra_files(['Main.hs', 'X1.hs', 'X2.hs'])], run_command, ['$MAKE -s --no-print-directory recomp010'])
test('recomp010', [extra_files(['Main.hs', 'X1.hs', 'X2.hs'])], makefile_test, [])
......@@ -3,4 +3,4 @@
test('recomp011',
[extra_files(['Main.hs']),
when(arch('powerpc64') or arch('powerpc64le'), expect_broken(11260))],
run_command, ['$MAKE -s --no-print-directory recomp011'])
makefile_test, [])
# Test for #7215, a recompilation bug
test('recomp012', [], run_command, ['$MAKE -s --no-print-directory recomp012'])
test('recomp012', [], makefile_test, [])
# Test for #8247, a recompilation bug
test('recomp013', [], run_command, ['$MAKE -s --no-print-directory recomp013'])
test('recomp013', [], makefile_test, [])
......@@ -6,6 +6,5 @@ test('recomp015',
unless(opsys('linux') or opsys('solaris2') or opsys('openbsd'), skip),
when(arch('arm'), skip),
when(arch('powerpc64') or arch('powerpc64le'), expect_broken(11323))],
run_command,
['$MAKE -s --no-print-directory recomp015'])
makefile_test, [])
# Test for #12723, a recompilation bug
test('recomp016', [extra_files(['A.hs', 'A2.hs', 'C.hs', 'D.hs', 'E.hs'])], run_command, ['$MAKE -s --no-print-directory recomp016'])
test('recomp016',
[extra_files(['A.hs', 'A2.hs', 'C.hs', 'D.hs', 'E.hs'])],
makefile_test, [])
......@@ -3,4 +3,4 @@
test('recomp017',
[extra_files(['A.hs', 'B.hs', 'C.hs', 'C2.hs', 'D.hs', 'E.hs']),
ignore_stdout, expect_broken(13099)],
run_command, ['$MAKE -s --no-print-directory recomp017'])
makefile_test, [])
......@@ -2,4 +2,4 @@
test('recomp018',
[extra_files(['A.hs', 'B.hs', 'C.hs'])],
run_command, ['$MAKE -s --no-print-directory recomp018'])
makefile_test, [])
......@@ -2,6 +2,5 @@ test('retc001',
[extra_files(['A.hs', 'B1.hs', 'B2.hs', 'C.hs']),
# See issue 11204, this test sometimes passes and sometimes fails on OSX
when(opsys('darwin'), skip)],
run_command,
['$MAKE -s --no-print-directory retc001'])
makefile_test, [])
test('retc002', [extra_files(['Q.hs', 'W.hs', 'W.hs-boot']),
when(fast(), skip)], run_command,
['$MAKE -s --no-print-directory retc002'])
when(fast(), skip)],
makefile_test, [])
test('retc003', [extra_files(['A.hs'])], run_command, ['$MAKE -s --no-print-directory retc003'])
test('retc003', [extra_files(['A.hs'])], makefile_test, [])
test('T3807', [req_shared_libs, when(opsys('mingw32'), skip)], run_command,
['$MAKE --no-print-directory -s T3807'])
test('T3807', [req_shared_libs, when(opsys('mingw32'), skip)], makefile_test, [])
test('T4464', [req_shared_libs, unless(opsys('mingw32'), skip)], run_command,
['$MAKE --no-print-directory -s T4464'])
test('T4464', [req_shared_libs, unless(opsys('mingw32'), skip)], makefile_test, [])
test('T5373', [req_shared_libs], run_command,
['$MAKE --no-print-directory -s T5373'])
test('T5373', [req_shared_libs], makefile_test, [])
# It's not clear exactly what platforms we can expect this to succeed on.
test('T13702', unless(opsys('linux'), skip), run_command,
['$MAKE --no-print-directory -s T13702'])
test('T13702', unless(opsys('linux'), skip), makefile_test, [])
......@@ -160,11 +160,11 @@ test('T5594', [ omit_ways(['ghci']),
# needs it.
compile_and_run, ['T5594_c.c -no-hs-main'])
test('Capi_Ctype_001', [extra_files(['Capi_Ctype_A_001.hsc', 'capi_ctype_001.h', 'capi_ctype_001_c.c'])], run_command,
['$MAKE -s --no-print-directory Capi_Ctype_001'])
test('Capi_Ctype_001', [extra_files(['Capi_Ctype_A_001.hsc', 'capi_ctype_001.h', 'capi_ctype_001_c.c'])],
makefile_test, ['Capi_Ctype_001'])
test('Capi_Ctype_002', [extra_files(['Capi_Ctype_A_002.hsc', 'capi_ctype_002_A.h', 'capi_ctype_002_B.h'])], run_command,
['$MAKE -s --no-print-directory Capi_Ctype_002'])
test('Capi_Ctype_002', [extra_files(['Capi_Ctype_A_002.hsc', 'capi_ctype_002_A.h', 'capi_ctype_002_B.h'])],
makefile_test, ['Capi_Ctype_002'])
test('ffi_parsing_001', [omit_ways(['ghci'])], compile_and_run,
['ffi_parsing_001_c.c'])
......
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