summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-02-19 15:24:55 -0500
committerNed Batchelder <ned@nedbatchelder.com>2018-02-19 15:24:55 -0500
commit2ea70fbacc628259487e248b2b5a88c5b4eab5ac (patch)
tree6d5d535e178834e8ab0af1aea5b057ee124976e9 /tests
parent6872784b1e228196992eab018d61e1f76c2815d2 (diff)
downloadpython-coveragepy-2ea70fbacc628259487e248b2b5a88c5b4eab5ac.tar.gz
Make a test a little more specific
Diffstat (limited to 'tests')
-rw-r--r--tests/test_process.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/test_process.py b/tests/test_process.py
index 18564cb..35dddd0 100644
--- a/tests/test_process.py
+++ b/tests/test_process.py
@@ -676,9 +676,11 @@ class ProcessTest(CoverageTest):
pass
""")
self.make_file("run_twice.py", """\
+ import sys
import coverage
- for _ in [1, 2]:
+ for i in [1, 2]:
+ sys.stderr.write("Run %s\\n" % i)
inst = coverage.Coverage(source=['foo'])
inst.load()
inst.start()
@@ -689,6 +691,8 @@ class ProcessTest(CoverageTest):
out = self.run_command("python run_twice.py")
self.assertEqual(
out,
+ "Run 1\n"
+ "Run 2\n"
"Coverage.py warning: Module foo was previously imported, but not measured "
"(module-not-measured)\n"
)