Skip to content

Commit

Permalink
Don't be fooled by "coverage" in a path.
Browse files Browse the repository at this point in the history
  • Loading branch information
nedbat authored and ionelmc committed Aug 4, 2019
1 parent af0dde9 commit b551502
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/test_pytest_cov.py
Expand Up @@ -1658,7 +1658,11 @@ def test_disabled_output(testdir):
'--cov-report=',
script)

assert 'coverage' not in result.stdout.str()
stdout = result.stdout.str()
# We don't want the path to the executable to fail the test if we happen
# to put the project in a directory with "coverage" in it.
stdout = stdout.replace(sys.executable, "<SYS.EXECUTABLE>")
assert 'coverage' not in stdout
assert result.ret == 0


Expand Down

0 comments on commit b551502

Please sign in to comment.