Check conftest.py is not loaded with --confcutdir.

The test creates a conftest.py with "assert 0" which never should be loaded.
However, if it were loaded, the test would still pass as it never checks if it
was loaded or not.

See #799.
This commit is contained in:
Florian Bruhin 2015-06-23 09:56:25 +02:00
parent cdd25c9512
commit 01d067ec2b
1 changed files with 1 additions and 0 deletions

View File

@ -171,6 +171,7 @@ def test_conftest_confcutdir(testdir):
"""))
result = testdir.runpytest("-h", "--confcutdir=%s" % x, x)
result.stdout.fnmatch_lines(["*--xyz*"])
assert 'warning: could not load initial' not in result.stdout.str()
def test_conftest_existing_resultlog(testdir):
x = testdir.mkdir("tests")