summaryrefslogtreecommitdiffstats
path: root/runtest.py
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2004-01-27 06:35:04 (GMT)
committerSteven Knight <knight@baldmt.com>2004-01-27 06:35:04 (GMT)
commit337d309e434809058ceb356b40f7415d7c07cc09 (patch)
treefaf09e444cbecbeafdc012c1e686a394c6eb156c /runtest.py
parent4e3b37959a38511c32b997a9c60efac699e5a635 (diff)
downloadSCons-337d309e434809058ceb356b40f7415d7c07cc09.zip
SCons-337d309e434809058ceb356b40f7415d7c07cc09.tar.gz
SCons-337d309e434809058ceb356b40f7415d7c07cc09.tar.bz2
Accomodate white space in path names when running tests.
Diffstat (limited to 'runtest.py')
-rw-r--r--runtest.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/runtest.py b/runtest.py
index fd421ef..9a0cadd 100644
--- a/runtest.py
+++ b/runtest.py
@@ -354,8 +354,15 @@ class Unbuffered:
sys.stdout = Unbuffered(sys.stdout)
+_ws = re.compile('\s')
+
+def escape(s):
+ if _ws.search(s):
+ s = '"' + s + '"'
+ return s
+
for t in tests:
- cmd = string.join([python, debug, t.abspath], " ")
+ cmd = string.join(map(escape, [python, debug, t.abspath]), " ")
if printcmd:
sys.stdout.write(cmd + "\n")
s = os.system(cmd)