Skip to content

Commit

Permalink
tests: xfail tests until we work on them (#975)
Browse files Browse the repository at this point in the history
* xfail tests until we work on them

* more xfail for pypy

* Apply suggestions from code review

---------

Co-authored-by: Mickaël Schoentgen <contact@tiger-222.fr>
  • Loading branch information
altendky and BoboTiG committed Mar 15, 2023
1 parent 344f342 commit ddb9bd1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
18 changes: 17 additions & 1 deletion tests/test_0_watchmedo.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,10 @@ def test_auto_restart_on_file_change(tmpdir, capfd):
assert trick.restart_count == 3


@pytest.mark.xfail(
condition=sys.platform.startswith(("win", "darwin")) or sys.implementation.name == "pypy",
reason="known to be problematic, see #973",
)
def test_auto_restart_on_file_change_debounce(tmpdir, capfd):
"""Simulate changing 3 files quickly and then another change later.
Expand All @@ -173,7 +177,19 @@ def test_auto_restart_on_file_change_debounce(tmpdir, capfd):
assert trick.restart_count == 2


@pytest.mark.parametrize("restart_on_command_exit", [True, False])
@pytest.mark.parametrize(
"restart_on_command_exit",
[
True,
pytest.param(
False,
marks=pytest.mark.xfail(
condition=sys.platform.startswith(("win", "darwin")),
reason="known to be problematic, see #972",
),
),
],
)
def test_auto_restart_subprocess_termination(tmpdir, capfd, restart_on_command_exit):
"""Run auto-restart with a script that terminates in about 2 seconds.
Expand Down
1 change: 1 addition & 0 deletions tests/test_emitter.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ def test_create():
assert isinstance(event, FileClosedEvent)


@pytest.mark.xfail(reason="known to be problematic")
@pytest.mark.skipif(
not platform.is_linux(), reason="FileCloseEvent only supported in GNU/Linux"
)
Expand Down

0 comments on commit ddb9bd1

Please sign in to comment.