Ignore hidden files (.testmondata) in test_pytest_collect_file
`test_pytest_collect_file` fails if you run the tests using `--testmon`, because pytest-testmon will put its DB there as `.testmondata`.
This commit is contained in:
parent
d81ee9acfb
commit
e9d7989140
|
@ -150,6 +150,8 @@ class TestCollectPluginHookRelay:
|
|||
wascalled = []
|
||||
class Plugin:
|
||||
def pytest_collect_file(self, path, parent):
|
||||
if not path.basename.startswith("."):
|
||||
# Ignore hidden files, e.g. .testmondata.
|
||||
wascalled.append(path)
|
||||
testdir.makefile(".abc", "xyz")
|
||||
pytest.main([testdir.tmpdir], plugins=[Plugin()])
|
||||
|
|
Loading…
Reference in New Issue