@pytest.hookimpl(tryfirst=True, hookwrapper=True)
def pytest_runtest_makereport(item, call):
 outcome = (yield)
 rep = outcome.get_result()
 setattr(item, ('rep_' + rep.when), rep)

@ pytest . hookimpl ( tryfirst = True , hookwrapper = True ) def pytest_runtest_makereport ( item , call ) : outcome = ( yield ) rep = outcome . get_result ( ) setattr ( item , ( 'rep_' + rep . when ) , rep )
make test information available in fixtures .