1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
|
import pytest
def pytest_configure(config):
config.addinivalue_line("markers", "networked_tests: enable MusicBrainz and AcoustID test")
def pytest_addoption(parser):
parser.addoption(
"--networked_tests",
action="store_true",
help="Enable MusicBrainz and AcoustID test; not recommended unless you're doing development on them", # noqa: E501
)
def pytest_runtest_setup(item):
if "networked_tests" in item.keywords and not item.config.getoption("--networked_tests"):
pytest.skip("need --networked_tests option to run this test")
|