adding s3 model tests with --runslow

This commit is contained in:
thomwolf
2019-04-17 11:58:27 +02:00
parent 8407429d74
commit 31d387604c
10 changed files with 106 additions and 9 deletions

19
tests/conftest.py Normal file
View File

@@ -0,0 +1,19 @@
# content of conftest.py
import pytest
def pytest_addoption(parser):
parser.addoption(
"--runslow", action="store_true", default=False, help="run slow tests"
)
def pytest_collection_modifyitems(config, items):
if config.getoption("--runslow"):
# --runslow given in cli: do not skip slow tests
return
skip_slow = pytest.mark.skip(reason="need --runslow option to run")
for item in items:
if "slow" in item.keywords:
item.add_marker(skip_slow)