From 14fb32fe61d4cdb15f7ae699b55eaf60bc18ff5b Mon Sep 17 00:00:00 2001 From: Mats Wichmann Date: Fri, 7 Feb 2020 14:35:23 -0700 Subject: Fix a couple of tests After a change to the tool itself, the update-release-info test needed an update to match. This doesn't seem to be sufficient yet. The SPAWN test was updated for this PR, but broke on Windows because apparently too much quoting for calling via subprocess. Dropped the special-case windows quoting in the test itself. Signed-off-by: Mats Wichmann --- test/SPAWN.py | 7 +++---- test/update-release-info/update-release-info.py | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/test/SPAWN.py b/test/SPAWN.py index 1949eb6..ca9d344 100644 --- a/test/SPAWN.py +++ b/test/SPAWN.py @@ -45,18 +45,17 @@ with open(sys.argv[1], 'wb') as ofp: test.write('SConstruct', """ import subprocess import sys + def my_spawn1(sh, escape, cmd, args, env): s = " ".join(args + ['extra1.txt']) - if sys.platform in ['win32']: - s = '"' + s + '"' cp = subprocess.run(s, shell=True) return cp.returncode + def my_spawn2(sh, escape, cmd, args, env): s = " ".join(args + ['extra2.txt']) - if sys.platform in ['win32']: - s = '"' + s + '"' cp = subprocess.run(s, shell=True) return cp.returncode + env = Environment(MY_SPAWN1 = my_spawn1, MY_SPAWN2 = my_spawn2, COMMAND = r'%(_python_)s cat.py $TARGET $SOURCES') diff --git a/test/update-release-info/update-release-info.py b/test/update-release-info/update-release-info.py index d0242a8..0a7f08f 100644 --- a/test/update-release-info/update-release-info.py +++ b/test/update-release-info/update-release-info.py @@ -110,7 +110,7 @@ combo_fail(0, 2) combo_fail(1, 2) combo_fail(0, 1, 2, stdout = """ERROR: `bad' is not a valid release type in version tuple; -\tit must be one of alpha, beta, candidate, or final +\tit must be one of dev, beta, candidate, or final """) # We won't need this entry again, so put in a default -- cgit v0.12