summaryrefslogtreecommitdiff
path: root/test/backtest.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2009-12-03 08:54:27 -0500
committerNed Batchelder <ned@nedbatchelder.com>2009-12-03 08:54:27 -0500
commit5f7375fb90aaf728ebf6c9da9a61b5302dcbd71b (patch)
tree60f4c9265e686d2685c1a10d4a4acdff04ef7f79 /test/backtest.py
parente0b2014fad18f284256c94422d940ceb84e8be24 (diff)
parent99a3e92e89c3e9d4a0dd73ae71b0b849d7fddbee (diff)
downloadpython-coveragepy-5f7375fb90aaf728ebf6c9da9a61b5302dcbd71b.tar.gz
Merged default onto config.
Diffstat (limited to 'test/backtest.py')
-rw-r--r--test/backtest.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/backtest.py b/test/backtest.py
index 21a14d6..12bdbc9 100644
--- a/test/backtest.py
+++ b/test/backtest.py
@@ -12,18 +12,18 @@ try:
except ImportError:
def run_command(cmd):
"""Run a command in a subprocess.
-
+
Returns the exit code and the combined stdout and stderr.
-
+
"""
_, stdouterr = os.popen4(cmd)
return 0, stdouterr.read()
else:
def run_command(cmd):
"""Run a command in a subprocess.
-
+
Returns the exit code and the combined stdout and stderr.
-
+
"""
if sys.hexversion > 0x03000000 and cmd.startswith("coverage "):
@@ -36,13 +36,13 @@ else:
stderr=subprocess.STDOUT
)
retcode = proc.wait()
-
+
# Get the output, and canonicalize it to strings with newlines.
output = proc.stdout.read()
if not isinstance(output, str):
output = output.decode('utf-8')
output = output.replace('\r', '')
-
+
return retcode, output
# No more execfile in Py3k