[commit: ghc] master: Testsuite: make driver python 2.6 compatible again (5ca1d31)
git at git.haskell.org
git at git.haskell.org
Mon Oct 5 17:38:49 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/5ca1d312b4a0a4a118b476d8ed18d4769d205415/ghc
>---------------------------------------------------------------
commit 5ca1d312b4a0a4a118b476d8ed18d4769d205415
Author: Thomas Miedema <thomasmiedema at gmail.com>
Date: Mon Oct 5 17:32:02 2015 +0200
Testsuite: make driver python 2.6 compatible again
Reviewed by: kgardas
Differential Revision: https://phabricator.haskell.org/D1311
>---------------------------------------------------------------
5ca1d312b4a0a4a118b476d8ed18d4769d205415
testsuite/driver/testlib.py | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py
index 5ca17f2..3ca5d02 100644
--- a/testsuite/driver/testlib.py
+++ b/testsuite/driver/testlib.py
@@ -1646,14 +1646,14 @@ def compare_outputs(way, kind, normaliser, expected_file, actual_file,
if config.verbose >= 1 and _expect_pass(way):
# See Note [Output comparison].
- r = os.system('diff -uw {} {}'.format(expected_normalised_path,
- actual_normalised_path))
+ r = os.system('diff -uw {0} {1}'.format(expected_normalised_path,
+ actual_normalised_path))
# If for some reason there were no non-whitespace differences,
# then do a full diff
if r == 0:
- r = os.system('diff -u {} {}'.format(expected_normalised_path,
- actual_normalised_path))
+ r = os.system('diff -u {0} {1}'.format(expected_normalised_path,
+ actual_normalised_path))
if config.accept and (getTestOpts().expect == 'fail' or
way in getTestOpts().expect_fail_for):
@@ -1691,7 +1691,7 @@ def normalise_callstacks(str):
def repl(matches):
location = matches.group(1)
location = normalise_slashes_(location)
- return ', called at {}:<line>:<column> in <package-id>:'.format(location)
+ return ', called at {0}:<line>:<column> in <package-id>:'.format(location)
# Ignore line number differences in call stacks (#10834).
return re.sub(', called at (.+):[\\d]+:[\\d]+ in [\\w\-\.]+:', repl, str)
@@ -1818,7 +1818,7 @@ def rawSystemWithTimeout(cmd_and_args):
if r == 99 and getTestOpts().exit_code != 99:
# Only print a message when timeout killed the process unexpectedly.
cmd = cmd_and_args[-1]
- if_verbose(1, 'Timeout happened...killed process "{}"...\n'.format(cmd))
+ if_verbose(1, 'Timeout happened...killed process "{0}"...\n'.format(cmd))
return r
# cmd is a complex command in Bourne-shell syntax
More information about the ghc-commits
mailing list