Skip to content

Commit 316a89b

Browse files
committed
fix mocked RunShellCmdResult in systemtools tests
1 parent efbfd20 commit 316a89b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/framework/systemtools.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,8 @@ def mocked_run_shell_cmd(cmd, **kwargs):
340340
"ulimit -u": '40',
341341
}
342342
if cmd in known_cmds:
343-
return RunShellCmdResult(cmd=cmd, exit_code=0, output=known_cmds[cmd], stderr=None, work_dir=os.getcwd())
343+
return RunShellCmdResult(cmd=cmd, exit_code=0, output=known_cmds[cmd], stderr=None, work_dir=os.getcwd(),
344+
out_file=None, err_file=None)
344345
else:
345346
return run_shell_cmd(cmd, **kwargs)
346347

@@ -775,7 +776,8 @@ def test_gcc_version_darwin(self):
775776
st.get_os_type = lambda: st.DARWIN
776777
out = "Apple LLVM version 7.0.0 (clang-700.1.76)"
777778
cwd = os.getcwd()
778-
mocked_run_res = RunShellCmdResult(cmd="gcc --version", exit_code=0, output=out, stderr=None, work_dir=cwd)
779+
mocked_run_res = RunShellCmdResult(cmd="gcc --version", exit_code=0, output=out, stderr=None, work_dir=cwd,
780+
out_file=None, err_file=None)
779781
st.run_shell_cmd = lambda *args, **kwargs: mocked_run_res
780782
self.assertEqual(get_gcc_version(), None)
781783

0 commit comments

Comments
 (0)