Add test suite for #8602
authorChris Heller <hellertime@gmail.com>
Thu, 2 Jan 2014 21:54:58 +0000 (16:54 -0500)
committerAustin Seipp <austin@well-typed.com>
Tue, 7 Jan 2014 13:08:56 +0000 (07:08 -0600)
Signed-off-by: Austin Seipp <austin@well-typed.com>
testsuite/tests/driver/T8602/A.hs [new file with mode: 0644]
testsuite/tests/driver/T8602/T8602.T [new file with mode: 0644]
testsuite/tests/driver/T8602/T8602.script [new file with mode: 0644]
testsuite/tests/driver/T8602/T8602.stderr [new file with mode: 0644]

diff --git a/testsuite/tests/driver/T8602/A.hs b/testsuite/tests/driver/T8602/A.hs
new file mode 100644 (file)
index 0000000..3203d94
--- /dev/null
@@ -0,0 +1 @@
+{-# OPTIONS_GHC -F -pgmF ./t8602.sh -optF A -optF B -optF C #-}
diff --git a/testsuite/tests/driver/T8602/T8602.T b/testsuite/tests/driver/T8602/T8602.T
new file mode 100644 (file)
index 0000000..87fa8b6
--- /dev/null
@@ -0,0 +1 @@
+test('T8602', extra_clean(['t8602.sh']), ghci_script, ['T8602.script'])
diff --git a/testsuite/tests/driver/T8602/T8602.script b/testsuite/tests/driver/T8602/T8602.script
new file mode 100644 (file)
index 0000000..746fb09
--- /dev/null
@@ -0,0 +1,3 @@
+:! echo 'echo $4 $5 $6; exit 1' > t8602.sh
+:! chmod +x t8602.sh
+:load A
diff --git a/testsuite/tests/driver/T8602/T8602.stderr b/testsuite/tests/driver/T8602/T8602.stderr
new file mode 100644 (file)
index 0000000..3bbfa20
--- /dev/null
@@ -0,0 +1,2 @@
+A B C
+phase `Haskell pre-processor' failed (exitcode = 1)