diff options
-rw-r--r-- | testsuite/driver/runtests.py | 8 | ||||
-rw-r--r-- | testsuite/driver/testlib.py | 12 | ||||
-rw-r--r-- | testsuite/tests/ghc-regress/lib/should_run/all.T | 7 |
3 files changed, 26 insertions, 1 deletions
diff --git a/testsuite/driver/runtests.py b/testsuite/driver/runtests.py index 45bdd010cd..a6b0da5cfd 100644 --- a/testsuite/driver/runtests.py +++ b/testsuite/driver/runtests.py @@ -106,6 +106,14 @@ if config.use_threads == 1: print "Warning: Ignoring request to use threads as running on Windows" config.use_threads = 0 +config.cygwin = False +config.msys = False +if windows: + if cygwin: + config.cygwin = True + else: + config.msys = True + # Try to use UTF8 if windows: import ctypes diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 0dce28c4aa..f48b86df81 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -278,6 +278,18 @@ def if_wordsize( ws, f ): else: return normal +def if_msys( f ): + if config.msys: + return f + else: + return normal + +def if_cygwin( f ): + if config.cygwin: + return f + else: + return normal + # --- def if_in_tree_compiler( f ): diff --git a/testsuite/tests/ghc-regress/lib/should_run/all.T b/testsuite/tests/ghc-regress/lib/should_run/all.T index 388ad043ed..c0b7384f88 100644 --- a/testsuite/tests/ghc-regress/lib/should_run/all.T +++ b/testsuite/tests/ghc-regress/lib/should_run/all.T @@ -57,4 +57,9 @@ test('stableptr005', normal, compile_and_run, ['']) test('weak001', normal, compile_and_run, ['']) -test('4006', normal, compile_and_run, ['']) +# In the 65001 codepage, we can't even cat the expected output on msys: +# $ cat 4006.stdout +# It works here +# cat: write error: Permission denied +test('4006', if_msys(expect_fail), compile_and_run, ['']) + |