I tried to use the norecursedirs option inside setup.cfg to tell py.test not to collect tests from certain directories but it seems it does ignore it.
[tool:pyte
norecursedirs should work. Check whether you have a pytest.ini or other setup.cfg files. How are you invoking py.test?
norecursedirs
py.test