Skip to content

Commit 2dd4785

Browse files
committed
ENH: allow glob patterns in pytest_extra_ignore
Use fnmatch_ex from _pytest.pathlib to match pytest itself.
1 parent e96c2d0 commit 2dd4785

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scipy_doctest/plugin.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,9 @@ def pytest_ignore_collect(collection_path, config):
8282
if "tests" in path_str or "test_" in path_str:
8383
return True
8484

85+
fnmatch_ex = _pytest.pathlib.fnmatch_ex
8586
for entry in config.dt_config.pytest_extra_ignore:
86-
if entry in str(collection_path):
87+
if fnmatch_ex(entry, collection_path):
8788
return True
8889

8990

0 commit comments

Comments
 (0)