summaryrefslogtreecommitdiff
path: root/testsuite/tests/cabal
diff options
context:
space:
mode:
authorReid Barton <rwbarton@gmail.com>2017-02-24 21:14:50 -0500
committerBen Gamari <ben@smart-cactus.org>2017-02-26 17:30:48 -0500
commit3415bcaa0b1903b5e12dfaadb5b774718e406eab (patch)
treef87cea33d55f1b196069e213e413019d8e9c6c3a /testsuite/tests/cabal
parent98119f5a5224d321a1765f262c8c76dfd1b8ed35 (diff)
downloadhaskell-3415bcaa0b1903b5e12dfaadb5b774718e406eab.tar.gz
tests: remove extra_files.py (#12223)
The script I used is included as testsuite/driver/kill_extra_files.py, though at this point it is for mostly historical interest. Some of the tests in libraries/hpc relied on extra_files.py, so this commit includes an update to that submodule. One test in libraries/process also relies on extra_files.py, but we cannot update that submodule so easily, so for now we special-case it in the test driver.
Diffstat (limited to 'testsuite/tests/cabal')
-rw-r--r--testsuite/tests/cabal/T12485/all.T2
-rw-r--r--testsuite/tests/cabal/T12733/all.T2
-rw-r--r--testsuite/tests/cabal/all.T25
-rw-r--r--testsuite/tests/cabal/cabal03/all.T2
-rw-r--r--testsuite/tests/cabal/cabal04/all.T2
-rw-r--r--testsuite/tests/cabal/cabal05/all.T2
-rw-r--r--testsuite/tests/cabal/cabal06/all.T2
-rw-r--r--testsuite/tests/cabal/cabal08/all.T2
-rw-r--r--testsuite/tests/cabal/cabal09/all.T2
-rw-r--r--testsuite/tests/cabal/pkg02/all.T2
10 files changed, 23 insertions, 20 deletions
diff --git a/testsuite/tests/cabal/T12485/all.T b/testsuite/tests/cabal/T12485/all.T
index f6998973ea..709943c96e 100644
--- a/testsuite/tests/cabal/T12485/all.T
+++ b/testsuite/tests/cabal/T12485/all.T
@@ -1 +1 @@
-test('T12485', [], run_command, ['$MAKE -s --no-print-directory T12485'])
+test('T12485', [extra_files(['a.pkg', 'b.pkg', 'Main.hs'])], run_command, ['$MAKE -s --no-print-directory T12485'])
diff --git a/testsuite/tests/cabal/T12733/all.T b/testsuite/tests/cabal/T12733/all.T
index 8b00daa66a..a9cf30f441 100644
--- a/testsuite/tests/cabal/T12733/all.T
+++ b/testsuite/tests/cabal/T12733/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('T12733',
- normal,
+ extra_files(['p/', 'q/', 'Setup.hs']),
run_command,
['$MAKE -s --no-print-directory T12733 ' + cleanup])
diff --git a/testsuite/tests/cabal/all.T b/testsuite/tests/cabal/all.T
index fc7269c4f3..23c4826e35 100644
--- a/testsuite/tests/cabal/all.T
+++ b/testsuite/tests/cabal/all.T
@@ -1,14 +1,15 @@
def normaliseDynlibNames(str):
return re.sub('-ghc[0-9.]+\.', '-ghc<VERSION>.', str)
-test('ghcpkg01', [], run_command, ['$MAKE -s --no-print-directory ghcpkg01'])
+test('ghcpkg01', [extra_files(['test.pkg', 'test2.pkg', 'test3.pkg'])], run_command, ['$MAKE -s --no-print-directory ghcpkg01'])
# Use ignore_stderr to prevent (when HADDOCK_DOCS=NO):
# warning: haddock-interfaces .. doesn't exist or isn't a file
test('ghcpkg02', [ignore_stderr], run_command,
['$MAKE -s --no-print-directory ghcpkg02'])
-test('ghcpkg03', [normalise_errmsg_fun(normaliseDynlibNames)], run_command,
+test('ghcpkg03', [extra_files(['test.pkg', 'test2.pkg', 'test4.pkg']),
+ normalise_errmsg_fun(normaliseDynlibNames)], run_command,
['$MAKE -s --no-print-directory ghcpkg03'])
def normalise_package_order(s):
@@ -17,7 +18,8 @@ def normalise_package_order(s):
'newtestpkg-2.0 testpkg-1.2.3.4',
s)
-test('ghcpkg04', [normalise_errmsg_fun(normalise_package_order)], run_command,
+test('ghcpkg04', [extra_files(['test.pkg', 'test5.pkg']),
+ normalise_errmsg_fun(normalise_package_order)], run_command,
['$MAKE -s --no-print-directory ghcpkg04'])
# Sometimes we get spurious warnings from ghc-pkg about missing
@@ -26,11 +28,12 @@ def normalise_haddock_junk( str ):
return re.sub(r'Warning: haddock.*\n', '', str)
test('ghcpkg05',
- [normalise_errmsg_fun(normalise_haddock_junk, normaliseDynlibNames)],
+ [extra_files(['test2.pkg', 'test3.pkg']),
+ normalise_errmsg_fun(normalise_haddock_junk, normaliseDynlibNames)],
run_command, ['$MAKE -s --no-print-directory ghcpkg05'])
-test('ghcpkg06', [], run_command, ['$MAKE -s --no-print-directory ghcpkg06'])
+test('ghcpkg06', [extra_files(['test.pkg', 'testdup.pkg'])], run_command, ['$MAKE -s --no-print-directory ghcpkg06'])
-test('ghcpkg07', [], run_command, ['$MAKE -s --no-print-directory ghcpkg07'])
+test('ghcpkg07', [extra_files(['test.pkg', 'test7a.pkg', 'test7b.pkg'])], run_command, ['$MAKE -s --no-print-directory ghcpkg07'])
# Test that we *can* compile a module that also belongs to a package
# (this was disallowed in GHC 6.4 and earlier)
@@ -38,14 +41,14 @@ test('pkg01', normal, compile, [''])
test('T1750', [], run_command, ['$MAKE -s --no-print-directory T1750'])
-test('T5442a', [], run_command, ['$MAKE -s --no-print-directory T5442a'])
+test('T5442a', [extra_files(['test.pkg'])], run_command, ['$MAKE -s --no-print-directory T5442a'])
-test('T5442b', [], run_command, ['$MAKE -s --no-print-directory T5442b'])
+test('T5442b', [extra_files(['test.pkg'])], run_command, ['$MAKE -s --no-print-directory T5442b'])
-test('T5442c', [], run_command, ['$MAKE -s --no-print-directory T5442c'])
+test('T5442c', [extra_files(['test.pkg'])], run_command, ['$MAKE -s --no-print-directory T5442c'])
-test('T5442d', [], run_command, ['$MAKE -s --no-print-directory T5442d'])
+test('T5442d', [extra_files(['shadow1.pkg', 'shadow2.pkg', 'shadow4.pkg'])], run_command, ['$MAKE -s --no-print-directory T5442d'])
test('shadow', [], run_command, ['$MAKE -s --no-print-directory shadow'])
-test('T12485a', [], run_command, ['$MAKE -s --no-print-directory T12485a'])
+test('T12485a', [extra_files(['shadow1.pkg', 'shadow2.pkg', 'shadow3.pkg'])], run_command, ['$MAKE -s --no-print-directory T12485a'])
diff --git a/testsuite/tests/cabal/cabal03/all.T b/testsuite/tests/cabal/cabal03/all.T
index 822d35ef81..938d0e4c48 100644
--- a/testsuite/tests/cabal/cabal03/all.T
+++ b/testsuite/tests/cabal/cabal03/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal03',
- normal,
+ extra_files(['Setup.lhs', 'p/', 'q/', 'r/']),
run_command,
['$MAKE -s --no-print-directory cabal03 ' + cleanup])
diff --git a/testsuite/tests/cabal/cabal04/all.T b/testsuite/tests/cabal/cabal04/all.T
index e69b540f2a..3a4756026a 100644
--- a/testsuite/tests/cabal/cabal04/all.T
+++ b/testsuite/tests/cabal/cabal04/all.T
@@ -19,6 +19,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal04',
- normal,
+ extra_files(['Library.hs', 'Setup.lhs', 'TH.hs', 'thtest.cabal']),
run_command,
['$MAKE -s --no-print-directory cabal04 VANILLA=' + vanilla + ' PROF=' + prof + ' DYN=' + dyn + ' ' + cleanup])
diff --git a/testsuite/tests/cabal/cabal05/all.T b/testsuite/tests/cabal/cabal05/all.T
index aa209c8f49..0a2a0fd670 100644
--- a/testsuite/tests/cabal/cabal05/all.T
+++ b/testsuite/tests/cabal/cabal05/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal05',
- normal,
+ extra_files(['Setup.hs', 'p/', 'q/', 'r/', 's/', 't/']),
run_command,
['$MAKE -s --no-print-directory cabal05 ' + cleanup])
diff --git a/testsuite/tests/cabal/cabal06/all.T b/testsuite/tests/cabal/cabal06/all.T
index 6568e074c3..aa53948738 100644
--- a/testsuite/tests/cabal/cabal06/all.T
+++ b/testsuite/tests/cabal/cabal06/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal06',
- normal,
+ extra_files(['Setup.hs', 'p-1.0/', 'p-1.1/', 'q/', 'r/']),
run_command,
['$MAKE -s --no-print-directory cabal06 ' + cleanup])
diff --git a/testsuite/tests/cabal/cabal08/all.T b/testsuite/tests/cabal/cabal08/all.T
index 3aaf185828..95864fdf96 100644
--- a/testsuite/tests/cabal/cabal08/all.T
+++ b/testsuite/tests/cabal/cabal08/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal08',
- normal,
+ extra_files(['Main.hs', 'Setup.hs', 'p1/', 'p2/']),
run_command,
['$MAKE -s --no-print-directory cabal08 ' + cleanup])
diff --git a/testsuite/tests/cabal/cabal09/all.T b/testsuite/tests/cabal/cabal09/all.T
index bd7761900d..438161b05b 100644
--- a/testsuite/tests/cabal/cabal09/all.T
+++ b/testsuite/tests/cabal/cabal09/all.T
@@ -4,6 +4,6 @@ else:
cleanup = 'CLEANUP=0'
test('cabal09',
- normal,
+ extra_files(['Main.hs', 'Setup.hs', 'reexport.cabal']),
run_command,
['$MAKE -s --no-print-directory cabal09 ' + cleanup])
diff --git a/testsuite/tests/cabal/pkg02/all.T b/testsuite/tests/cabal/pkg02/all.T
index 651e9f903b..c6efd6fe0d 100644
--- a/testsuite/tests/cabal/pkg02/all.T
+++ b/testsuite/tests/cabal/pkg02/all.T
@@ -3,4 +3,4 @@
# separate packages are allowed). Now it is a straightforward test
# for shadowing: the local Foreign module shadows the base package
# one.
-test('pkg02', [], multimod_compile, ['A', '-v0'])
+test('pkg02', [extra_files(['A.hs', 'Foreign.hs'])], multimod_compile, ['A', '-v0'])