[commit: ghc] master: Testsuite: fix WAY=ghci when LOCAL=0 (6d0a4fc)

git at git.haskell.org git at git.haskell.org
Mon Jun 20 14:37:16 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/6d0a4fc5af4ca2ff9b3db7168273a7ceb01c6c38/ghc

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

commit 6d0a4fc5af4ca2ff9b3db7168273a7ceb01c6c38
Author: Thomas Miedema <thomasmiedema at gmail.com>
Date:   Sun Jun 19 14:58:46 2016 +0200

    Testsuite: fix WAY=ghci when LOCAL=0


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

6d0a4fc5af4ca2ff9b3db7168273a7ceb01c6c38
 testsuite/driver/testlib.py | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py
index 8fc1481..4dce6e3 100644
--- a/testsuite/driver/testlib.py
+++ b/testsuite/driver/testlib.py
@@ -1320,7 +1320,7 @@ def simple_run(name, way, prog, extra_run_opts):
         use_stdin = opts.stdin
     else:
         stdin_file = add_suffix(name, 'stdin')
-        if os.path.exists(in_srcdir(stdin_file)):
+        if os.path.exists(in_testdir(stdin_file)):
             use_stdin = stdin_file
         else:
             use_stdin = '/dev/null'
@@ -1441,12 +1441,12 @@ def interpreter_run( name, way, extra_hc_opts, compile_only, top_mod ):
 
     # figure out what to use for stdin
     if getTestOpts().stdin != '':
-        stdin_file = in_srcdir(opts.stdin)
+        stdin_file = in_testdir(opts.stdin)
     else:
-        stdin_file = in_srcdir(name, 'stdin')
+        stdin_file = in_testdir(name, 'stdin')
 
     if os.path.exists(stdin_file):
-        os.system('cat ' + stdin_file + ' >>' + qscriptname)
+        os.system('cat "{0}" >> "{1}"'.format(stdin_file, qscriptname))
 
     flags = ' '.join(get_compiler_flags(override_flags=None, noforce=False) +
                      config.way_flags(name)[way])



More information about the ghc-commits mailing list