Skip to content

Commit 868f503

Browse files
committed
use pytest.skip instead of xfail
1 parent 31ca07c commit 868f503

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/conftest.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def pytest_collection_modifyitems(
2424
session: pytest.Session, config: pytest.config.Config, items: List[pytest.Item]
2525
) -> None:
2626
_mark_coros_as_async_tests(items)
27-
_xfail_driver_tests_on_windows(items)
27+
_skip_web_driver_tests_on_windows(items)
2828

2929

3030
def pytest_addoption(parser: Parser) -> None:
@@ -147,15 +147,15 @@ def _mark_coros_as_async_tests(items: List[pytest.Item]) -> None:
147147
item.add_marker(pytest.mark.asyncio)
148148

149149

150-
def _xfail_driver_tests_on_windows(items: List[pytest.Item]) -> None:
150+
def _skip_web_driver_tests_on_windows(items: List[pytest.Item]) -> None:
151151
if os.name == "nt":
152152
for item in items:
153153
if isinstance(item, pytest.Function):
154154
if {"display", "driver", "create_driver"}.intersection(
155155
item.fixturenames
156156
):
157157
item.add_marker(
158-
pytest.mark.xfail(
158+
pytest.mark.skip(
159159
reason="WebDriver tests are not working on Windows",
160160
)
161161
)

0 commit comments

Comments
 (0)