[commit: testsuite] master: Stop ghci025 sharing files with prog001 (ae48ac8)
Ian Lynagh
igloo at earth.li
Thu Sep 1 23:59:32 CEST 2011
Repository : ssh://darcs.haskell.org//srv/darcs/testsuite
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/ae48ac85594c6a5cc3f9acdb307901700ce2d091
>---------------------------------------------------------------
commit ae48ac85594c6a5cc3f9acdb307901700ce2d091
Author: Ian Lynagh <igloo at earth.li>
Date: Thu Sep 1 22:41:03 2011 +0100
Stop ghci025 sharing files with prog001
The tests could have failed if they ran in parallel
>---------------------------------------------------------------
tests/ghci/scripts/Ghci025B.hs | 5 +++
tests/ghci/{prog001/C.hs => scripts/Ghci025C.hs} | 4 +-
tests/ghci/{prog001/D1.hs => scripts/Ghci025D.hs} | 2 +-
tests/ghci/scripts/ghci025.script | 28 +++++++++-----------
tests/ghci/scripts/ghci025.stdout | 18 ++++++------
5 files changed, 30 insertions(+), 27 deletions(-)
diff --git a/tests/ghci/scripts/Ghci025B.hs b/tests/ghci/scripts/Ghci025B.hs
new file mode 100644
index 0000000..3218cf6
--- /dev/null
+++ b/tests/ghci/scripts/Ghci025B.hs
@@ -0,0 +1,5 @@
+module Ghci025B (module Ghci025B, module Ghci025C) where
+
+import Ghci025C
+
+k x = x `mod` 11
diff --git a/tests/ghci/prog001/C.hs b/tests/ghci/scripts/Ghci025C.hs
similarity index 52%
copy from tests/ghci/prog001/C.hs
copy to tests/ghci/scripts/Ghci025C.hs
index 006014f..9b73b6d 100644
--- a/tests/ghci/prog001/C.hs
+++ b/tests/ghci/scripts/Ghci025C.hs
@@ -1,6 +1,6 @@
-module C (f, g, h) where
+module Ghci025C (f, g, h) where
-import D
+import Ghci025D
g x = f x + 1
diff --git a/tests/ghci/prog001/D1.hs b/tests/ghci/scripts/Ghci025D.hs
similarity index 69%
copy from tests/ghci/prog001/D1.hs
copy to tests/ghci/scripts/Ghci025D.hs
index 35184c7..94a6e85 100644
--- a/tests/ghci/prog001/D1.hs
+++ b/tests/ghci/scripts/Ghci025D.hs
@@ -1,4 +1,4 @@
-module D where
+module Ghci025D where
data T = A Int | B Float deriving Eq
diff --git a/tests/ghci/scripts/ghci025.script b/tests/ghci/scripts/ghci025.script
index e4c1731..588e1e4 100644
--- a/tests/ghci/scripts/ghci025.script
+++ b/tests/ghci/scripts/ghci025.script
@@ -10,18 +10,16 @@ System.IO.putStrLn ":browse! T -- with -fprint-explicit-foralls"
System.IO.putStrLn "-- test :browse! <target> relative to different contexts"
:set -fforce-recomp
--- ToDo: this will go wrong in parallel
-:! cp ../prog001/D1.hs ../prog001/D.hs
-:l ../prog001/D.hs
-:add ../prog001/C.hs
-System.IO.putStrLn ":browse! C -- from *C>"
-:browse! C
-:add ../prog001/B.hs
-System.IO.putStrLn ":browse! C -- from *B>, after :add B"
-:browse! C
-:m *C
-System.IO.putStrLn ":browse! C -- from *C>, after :m *C"
-:browse! C
-:m *D
-System.IO.putStrLn ":browse! C -- from *D>, after :m *D"
-:browse! C
+:l Ghci025D.hs
+:add Ghci025C.hs
+System.IO.putStrLn ":browse! Ghci025C -- from *Ghci025C>"
+:browse! Ghci025C
+:add Ghci025B.hs
+System.IO.putStrLn ":browse! Ghci025C -- from *Ghci025B>, after :add Ghci025B"
+:browse! Ghci025C
+:m *Ghci025C
+System.IO.putStrLn ":browse! Ghci025C -- from *Ghci025C>, after :m *Ghci025C"
+:browse! Ghci025C
+:m *Ghci025D
+System.IO.putStrLn ":browse! Ghci025C -- from *Ghci025D>, after :m *Ghci025D"
+:browse! Ghci025C
diff --git a/tests/ghci/scripts/ghci025.stdout b/tests/ghci/scripts/ghci025.stdout
index 2c8a983..3650de2 100644
--- a/tests/ghci/scripts/ghci025.stdout
+++ b/tests/ghci/scripts/ghci025.stdout
@@ -86,26 +86,26 @@ c2 :: forall a b. (C a b, N b, S b) => a -> b
c3 :: forall a b. C a b => forall a1. a1 -> b
c4 :: forall a b. C a b => forall a1. a1 -> b
-- test :browse! <target> relative to different contexts
-:browse! C -- from *C>
+:browse! Ghci025C -- from *Ghci025C>
-- defined locally
g :: forall a. Num a => a -> a
h :: forall a. Integral a => a -> a
--- imported via D
+-- imported via Ghci025D
f :: forall a. Num a => a -> a
-:browse! C -- from *B>, after :add B
--- imported via C
+:browse! Ghci025C -- from *Ghci025B>, after :add Ghci025B
+-- imported via Ghci025C
g :: forall a. Num a => a -> a
h :: forall a. Integral a => a -> a
f :: forall a. Num a => a -> a
-:browse! C -- from *C>, after :m *C
+:browse! Ghci025C -- from *Ghci025C>, after :m *Ghci025C
-- defined locally
g :: forall a. Num a => a -> a
h :: forall a. Integral a => a -> a
--- imported via D
+-- imported via Ghci025D
f :: forall a. Num a => a -> a
-:browse! C -- from *D>, after :m *D
+:browse! Ghci025C -- from *Ghci025D>, after :m *Ghci025D
-- not currently imported
-C.g :: forall a. Num a => a -> a
-C.h :: forall a. Integral a => a -> a
+Ghci025C.g :: forall a. Num a => a -> a
+Ghci025C.h :: forall a. Integral a => a -> a
-- defined locally
f :: forall a. Num a => a -> a
More information about the Cvs-ghc
mailing list