diff options
Diffstat (limited to 'tests/conftest.py')
-rw-r--r-- | tests/conftest.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/conftest.py b/tests/conftest.py index 0047f7c3d..084acddc5 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -183,9 +183,10 @@ def pytest_collection_modifyitems(config, items): def pytest_ignore_collect(path): """Ignore BDD tests if we're unable to run them.""" + fspath = pathlib.Path(path) skip_bdd = hasattr(sys, 'frozen') - rel_path = path.relto(str(pathlib.Path(__file__).parent)) - return rel_path == pathlib.Path('end2end') / 'end2end' and skip_bdd + rel_path = fspath.is_relative_to(pathlib.Path(__file__).parent) + return rel_path == pathlib.Path('end2end') / 'features' and skip_bdd @pytest.fixture(scope='session') |