diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2015-10-25 19:28:29 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2015-10-25 19:28:29 -0400 |
commit | d30ed7bf6b327c3ba1cf95e3683a9d3305070449 (patch) | |
tree | ff13763b29302ddfc4d9f3e53cc9fe5f48ce23d5 /tests/helpers.py | |
parent | 207a3c22bdc6ab06946284b8916b6bd0b3ff256d (diff) | |
download | python-coveragepy-git-d30ed7bf6b327c3ba1cf95e3683a9d3305070449.tar.gz |
Diagnostic for appveyor
Diffstat (limited to 'tests/helpers.py')
-rw-r--r-- | tests/helpers.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/helpers.py b/tests/helpers.py index f0859f51..e85c7842 100644 --- a/tests/helpers.py +++ b/tests/helpers.py @@ -17,10 +17,12 @@ def run_command(cmd): # In some strange cases (PyPy3 in a virtualenv!?) the stdout encoding of # the subprocess is set incorrectly to ascii. Use an environment variable # to force the encoding to be the same as ours. + sub_env = dict(os.environ, PYTHONIOENCODING=sys.__stdout__.encoding) + print("SUB_ENV: %r" % (sub_env,)) proc = subprocess.Popen( cmd, shell=True, - env=dict(os.environ, PYTHONIOENCODING=sys.__stdout__.encoding), + env=sub_env, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT ) |