Repository : ssh://darcs.haskell.org//srv/darcs/testsuite On branch : master
http://hackage.haskell.org/trac/ghc/changeset/0437c0b59057abca37f0edc302560e2cf08dba84 >--------------------------------------------------------------- commit 0437c0b59057abca37f0edc302560e2cf08dba84 Author: Max Bolingbroke <[email protected]> Date: Sat Sep 24 22:01:06 2011 +0900 Attempt to fix decodingerror002 test for non-UTF8 locales >--------------------------------------------------------------- tests/lib/IO/decodingerror002.hs | 7 ++++++- tests/lib/IO/decodingerror002.stdout | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/lib/IO/decodingerror002.hs b/tests/lib/IO/decodingerror002.hs index 5b7acaf..a1a2373 100644 --- a/tests/lib/IO/decodingerror002.hs +++ b/tests/lib/IO/decodingerror002.hs @@ -3,7 +3,12 @@ import System.IO import System.IO.Error import GHC.IO.Handle (hSetEncoding) -main = alltests "decodingerror002.in" +main = do + -- Explicitly set stdout encoding so that the UTF8//ROUNDTRIP + -- test is always able to write the surrogate byte out without error. + enc <- mkTextEncoding "UTF8//ROUNDTRIP" + hSetEncoding stdout enc + alltests "decodingerror002.in" alltests file = mapM (test file) ["UTF8", "UTF8//IGNORE", diff --git a/tests/lib/IO/decodingerror002.stdout b/tests/lib/IO/decodingerror002.stdout index 6950fa4..e1cef33 100644 --- a/tests/lib/IO/decodingerror002.stdout +++ b/tests/lib/IO/decodingerror002.stdout @@ -1,4 +1,4 @@ Left decodingerror002.in: hGetChar: invalid argument (invalid byte sequence) Left decodingerror002.in: hGetChar: end of file �Left decodingerror002.in: hGetChar: end of file -Left <stdout>: hPutChar: invalid argument (invalid character) +ÈLeft decodingerror002.in: hGetChar: end of file
_______________________________________________ Cvs-ghc mailing list [email protected] http://www.haskell.org/mailman/listinfo/cvs-ghc
