summaryrefslogtreecommitdiff
path: root/testsuite/driver
diff options
context:
space:
mode:
authorThomas Miedema <thomasmiedema@gmail.com>2015-06-11 19:26:11 +0200
committerThomas Miedema <thomasmiedema@gmail.com>2015-06-11 19:26:11 +0200
commitda84fd5475d189c39bd3e12d29f45618c92ed800 (patch)
tree9d7c808f12d468dae7c6f9d2388de27d9f279ab7 /testsuite/driver
parentc1dc4216efc3db1a8fbd56a658981b53b7e42eda (diff)
downloadhaskell-da84fd5475d189c39bd3e12d29f45618c92ed800.tar.gz
Testsuite Windows: fix T8172 (#8172)
Use the new function `normalise_drive_letter` to change D:\ to C:\ before comparing outputs.
Diffstat (limited to 'testsuite/driver')
-rw-r--r--testsuite/driver/testlib.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py
index db3ada4544..671db9afb8 100644
--- a/testsuite/driver/testlib.py
+++ b/testsuite/driver/testlib.py
@@ -517,6 +517,10 @@ def normalise_version( *pkgs ):
_normalise_errmsg_fun(name, opts, normalise_version_(*pkgs))
return normalise_version__
+def normalise_drive_letter(name, opts):
+ # Windows only. Change D:\\ to C:\\.
+ _normalise_fun(name, opts, lambda str: re.sub(r'[A-Z]:\\', r'C:\\', str))
+
def join_normalisers(*a):
"""
Compose functions, flattening sequences.