diff options
author | Mats Wichmann <mats@linux.com> | 2020-02-07 18:52:53 (GMT) |
---|---|---|
committer | Mats Wichmann <mats@linux.com> | 2020-02-07 23:39:37 (GMT) |
commit | e8e8d71df80b9b690ef9f2d5b83378f23677e30f (patch) | |
tree | 975bfaf04b6b8d63d86fcb0827f4b8e8d226af73 /test/AS | |
parent | ef011014b343288919292560fa24e108874c059a (diff) | |
download | SCons-e8e8d71df80b9b690ef9f2d5b83378f23677e30f.zip SCons-e8e8d71df80b9b690ef9f2d5b83378f23677e30f.tar.gz SCons-e8e8d71df80b9b690ef9f2d5b83378f23677e30f.tar.bz2 |
Stop calling os.system in tests.
This converts the remaining tests that called os.system
themselves to use subprocess instead.
Signed-off-by: Mats Wichmann <mats@linux.com>
Diffstat (limited to 'test/AS')
-rw-r--r-- | test/AS/as-live.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/AS/as-live.py b/test/AS/as-live.py index b781caf..676b537 100644 --- a/test/AS/as-live.py +++ b/test/AS/as-live.py @@ -56,12 +56,12 @@ if sys.platform == "win32": testccc = "" test.write("wrapper.py", """\ -import os +import subprocess import sys with open('%s', 'wb') as f: f.write(("wrapper.py: %%s\\n" %% sys.argv[-1]).encode()) cmd = " ".join(sys.argv[1:]) -os.system(cmd) +subprocess.run(cmd, shell=True) """ % test.workpath('wrapper.out').replace('\\', '\\\\')) test.write('SConstruct', """\ |