Markers and fixtures¶
There are some builtin markers and fixtures in
@pytest.mark.no_cover def test_foobar(): # do some stuff that needs coverage disabled
Note that subprocess coverage will also be disabled.
def test_foobar(no_cover): # same as the marker ...
For reasons that no one can remember there is a
cov fixture that provides access to the underlying Coverage instance.
Some say this is a disguised foot-gun and should be removed, and some think mysteries make life more interesting and it should
be left alone.