[commit: testsuite] master: Test Trac #7995 (13841d3)

Simon Peyton Jones simonpj at microsoft.com
Mon Jun 24 19:17:52 CEST 2013


Repository : ssh://darcs.haskell.org//srv/darcs/testsuite

On branch  : master

https://github.com/ghc/testsuite/commit/13841d32e3004c3bb7b79b6b16cd949b9cf47aae

>---------------------------------------------------------------

commit 13841d32e3004c3bb7b79b6b16cd949b9cf47aae
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Mon Jun 24 18:17:42 2013 +0100

    Test Trac #7995

>---------------------------------------------------------------

 tests/simplCore/should_compile/Makefile     |    5 +++++
 tests/simplCore/should_compile/T7995.hs     |    6 ++++++
 tests/simplCore/should_compile/T7995.stdout |    1 +
 tests/simplCore/should_compile/all.T        |    5 +++++
 4 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/tests/simplCore/should_compile/Makefile b/tests/simplCore/should_compile/Makefile
index d87a211..6fb26b2 100644
--- a/tests/simplCore/should_compile/Makefile
+++ b/tests/simplCore/should_compile/Makefile
@@ -103,3 +103,8 @@ T7796:
 	'$(TEST_HC)' $(TEST_HC_OPTS) -O1 -c T7796.hs -ddump-prep > T7796.prep
 	(grep -q '$$w$$sgo' T7796.prep || echo 'could not find $$w$$sgo; compilation was not as expected')
 	-grep -c ' $$sgo' T7796.prep
+
+T7995:
+	$(RM) -f T7995.hi T7995.o
+	'$(TEST_HC)' $(TEST_HC_OPTS) -package ghc -ddump-rule-firings -c -O T7995.hs | grep 'text/str'
+
diff --git a/tests/simplCore/should_compile/T7995.hs b/tests/simplCore/should_compile/T7995.hs
new file mode 100644
index 0000000..75ebed7
--- /dev/null
+++ b/tests/simplCore/should_compile/T7995.hs
@@ -0,0 +1,6 @@
+-- We import Pretty from package ghc
+module T7995 where
+import Pretty
+
+
+foo = text "test"
diff --git a/tests/simplCore/should_compile/T7995.stdout b/tests/simplCore/should_compile/T7995.stdout
new file mode 100644
index 0000000..899ddff
--- /dev/null
+++ b/tests/simplCore/should_compile/T7995.stdout
@@ -0,0 +1 @@
+Rule fired: text/str
diff --git a/tests/simplCore/should_compile/all.T b/tests/simplCore/should_compile/all.T
index 31bef4d..d5dc2a3 100644
--- a/tests/simplCore/should_compile/all.T
+++ b/tests/simplCore/should_compile/all.T
@@ -179,3 +179,8 @@ test('T7702',
      compile, 
      ['-v0 -package-db T7702plugin/pkg.T7702/local.package.conf -fplugin T7702Plugin -package T7702plugin ' + config.ghci_way_flags])
 
+test('T7995',
+     normal,
+     run_command,
+     ['$MAKE -s --no-print-directory T7995'])
+





More information about the ghc-commits mailing list