Source code for fixtures.skip_not_implemented

import pytest


[docs]@pytest.mark.hookwrapper(tryfirst=True) def pytest_runtest_setup(item): """Pytest hook ensuring that failures caused by NotImplementedError show up as skips instead""" outcome = yield try: outcome.get_result() except NotImplementedError as e: pytest.skip(e)
[docs]@pytest.mark.hookwrapper(tryfirst=True) def pytest_runtest_call(item): """Pytest hook ensuring that failures caused by NotImplementedError show up as skips instead""" outcome = yield try: outcome.get_result() except NotImplementedError as e: pytest.skip(e)