August 2018
Beginner
160 pages
4h 8m
English
pytest by default will recurse over all subdirectories of the arguments given on the command line. This might make test collection take more time than desired when recursing into directories that never contain any tests, for example:
pytest by default tries to be smart and will not recurse inside folders with the patterns .*, build, dist, CVS, _darcs, {arch}, *.egg, venv. It also tries to detect virtualenvs automatically by looking at known locations for activation scripts.
The norecursedirs option can be used to override the default list of pattern names that pytest should never recurse into:
[pytest]norecursedirs = artifacts ...
Read now
Unlock full access