diff options
Diffstat (limited to 'mesontest.py')
-rwxr-xr-x | mesontest.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mesontest.py b/mesontest.py index cbfab6a..36f7334 100755 --- a/mesontest.py +++ b/mesontest.py @@ -132,7 +132,11 @@ def write_json_log(jsonlogfile, test_name, result): 'duration' : result.duration, 'returncode' : result.returncode, 'command' : result.cmd, - 'env' : result.env} + } + if isinstance(result.env, dict): + jresult['env'] = result.env + else: + jresult['env'] = result.env.get_env(os.environ) if result.stde: jresult['stderr'] = result.stde jsonlogfile.write(json.dumps(jresult) + '\n') |