A repo had test files in two locations: tests/ and in-package src/<pkg>/test_*.py. Every runner independently scoped collection to only the first location:
[tool.pytest.ini_options] testpaths = ["tests"] limits bare pytest runstox commands passed {tox_root}/tests/ explicitly, overriding nothing visibly./pkg/tests as the pytest argumentResult: dozens of in-package tests never ran anywhere — silently, for months. Proof of drift: running pytest directly on the in-package directory surfaced an assertion testing a contract value the code had since renamed; it failed immediately, meaning no runner had ever executed it after the rename.
Lessons:
testpaths only applies when pytest gets no positional args, so fixing it alone does not fix tox/CI invocations that pass explicit paths.pytest <each-test-root> directly and compare collected counts against your CI logs. A test that fails on first direct run is evidence it was never collected, not that it just broke.