Skip to content

Commit

Permalink
Add one more assertion to a test about COVERAGE_PROCESS_START.
Browse files Browse the repository at this point in the history
  • Loading branch information
nedbat committed Sep 15, 2013
1 parent 81c1e72 commit 4e2e0a0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/test_process.py
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ def setUp(self):
pass
finally:
pth.close()
else: # pragma: not covered
else: # pragma: not covered
raise Exception("Couldn't find a place for the .pth file")

def tearDown(self):
Expand Down Expand Up @@ -615,7 +615,9 @@ def test_subprocess_with_pth_files(self): # pragma: not covered
import main # pylint: disable=F0401,W0612

self.assertEqual(open("out.txt").read(), "Hello, world!\n")

# Read the data from .coverage
self.assert_exists(".mycovdata")
data = coverage.CoverageData()
data.read_file(".mycovdata")
self.assertEqual(data.summary()['sub.py'], 3)

0 comments on commit 4e2e0a0

Please sign in to comment.