[project @ 2001-05-21 14:08:36 by simonmar]
authorsimonmar <unknown>
Mon, 21 May 2001 14:08:36 +0000 (14:08 +0000)
committersimonmar <unknown>
Mon, 21 May 2001 14:08:36 +0000 (14:08 +0000)
Make it a bit clearer which output goes with which test.

ghc/tests/lib/IO/openFile005.hs
ghc/tests/lib/IO/openFile005.stdout

index fd2dfa8..e75e5b8 100644 (file)
@@ -6,38 +6,38 @@ file1 = "openFile005.out1"
 file2 = "openFile005.out2"
 
 main = do
-  -- two writes (should fail)
+  putStrLn "two writes (should fail)"
   h <- openFile file1 WriteMode
   try (openFile file1 WriteMode) >>= print
   hClose h
 
-  -- write and an append (should fail)
+  putStrLn "write and an append (should fail)"
   h <- openFile file1 WriteMode
   try (openFile file1 AppendMode) >>= print
   hClose h
 
-  -- read/write and a write (should fail)
+  putStrLn "read/write and a write (should fail)"
   h <- openFile file1 ReadWriteMode
   try (openFile file1 WriteMode) >>= print
   hClose h
 
-  -- read and a read/write (should fail)
+  putStrLn "read and a read/write (should fail)"
   h <- openFile file1 ReadMode
   try (openFile file1 ReadWriteMode) >>= print
   hClose h
 
-  -- write and a read (should fail)
+  putStrLn "write and a read (should fail)"
   h <- openFile file1 WriteMode
   try (openFile file1 ReadMode) >>= print
   hClose h
 
-  -- two writes, different files (silly, but should succeed)
+  putStrLn "two writes, different files (silly, but should succeed)"
   h1 <- openFile file1 WriteMode
   h2 <- openFile file2 WriteMode
   hClose h1
   hClose h2
 
-  -- two reads, should succeed
+  putStrLn "two reads, should succeed"
   h1 <- openFile file1 ReadMode
   h2 <- openFile file1 ReadMode
   hClose h1
index 6899c84..f32fff4 100644 (file)
@@ -1,20 +1,27 @@
+two writes (should fail)
 Left resource busy
 Action: openFile
 Reason: file is locked
 File: openFile005.out1
+write and an append (should fail)
 Left resource busy
 Action: openFile
 Reason: file is locked
 File: openFile005.out1
+read/write and a write (should fail)
 Left resource busy
 Action: openFile
 Reason: file is locked
 File: openFile005.out1
+read and a read/write (should fail)
 Left resource busy
 Action: openFile
 Reason: file is locked
 File: openFile005.out1
+write and a read (should fail)
 Left resource busy
 Action: openFile
 Reason: file is locked
 File: openFile005.out1
+two writes, different files (silly, but should succeed)
+two reads, should succeed