summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/utils/lit/lit/TestRunner.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/utils/lit/lit/TestRunner.py b/llvm/utils/lit/lit/TestRunner.py
index 8929c0b5776..a8150e62409 100644
--- a/llvm/utils/lit/lit/TestRunner.py
+++ b/llvm/utils/lit/lit/TestRunner.py
@@ -364,6 +364,15 @@ def parseIntegratedTestScript(test, normalize_slashes=False,
('%T', tmpDir),
('#_MARKER_#', '%')])
+ # "%/[STpst]" should be normalized.
+ substitutions.extend([
+ ('%/s', sourcepath.replace('\\', '/')),
+ ('%/S', sourcedir.replace('\\', '/')),
+ ('%/p', sourcedir.replace('\\', '/')),
+ ('%/t', tmpBase.replace('\\', '/') + '.tmp'),
+ ('%/T', tmpDir.replace('\\', '/')),
+ ])
+
# Collect the test lines from the script.
script = []
xfails = []
OpenPOWER on IntegriCloud