diff options
author | Thomas Miedema <thomasmiedema@gmail.com> | 2015-09-12 15:23:12 +0200 |
---|---|---|
committer | Thomas Miedema <thomasmiedema@gmail.com> | 2015-09-12 15:26:15 +0200 |
commit | 89324b82edaf5e02807617bffb5cf24c1d7a37af (patch) | |
tree | 481a8d889275f4c2bd10b1b77f17ae094f80f1bd /testsuite/driver | |
parent | 7ad4b3c1419fefbb01fd4643f374150abd1d11e2 (diff) | |
download | haskell-89324b82edaf5e02807617bffb5cf24c1d7a37af.tar.gz |
Testsuite: normalise slashes in callstack output
This fixes some tests on Windows, for example T2120.
Diffstat (limited to 'testsuite/driver')
-rw-r--r-- | testsuite/driver/testlib.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 6b3426ef40..170039222d 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -1681,10 +1681,12 @@ def normalise_whitespace( str ): return str.strip() def normalise_callstacks(str): + def repl(matches): + location = matches.group(1) + location = normalise_slashes_(location) + return ', called at {}:<line>:<column> in'.format(location) # Ignore line number differences in call stacks (#10834). - return re.sub(', called at (.+):[\\d]+:[\\d]+ in', - ', called at \\1:<line>:<column> in', - str) + return re.sub(', called at (.+):[\\d]+:[\\d]+ in', repl, str) def normalise_errmsg( str ): # remove " error:" and lower-case " Warning:" to make patch for |