Skip to content

Commit

Permalink
🧪 Stop using pytest-forked
Browse files Browse the repository at this point in the history
This plugin is incompatible with Pytest 7+, it's difficult to fix
upstream and there is no timeline for addressing that.

The patch also bumps the top version boundary of Pytest to 7.2 due
to the pinned `pytest-cov` raising warnings.

Fixes ##502
Resolves #511
Closes #680
Resolves #681
  • Loading branch information
jaraco authored and webknjaz committed Apr 27, 2024
1 parent ead1269 commit b9a1e28
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 15 deletions.
9 changes: 0 additions & 9 deletions cheroot/test/test_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -400,15 +400,6 @@ def test_reuse_port(http_server, ip_addr, mocker):
assert spy.spy_exception is None


ISSUE511 = IS_MACOS


if not IS_WINDOWS and not ISSUE511:
test_high_number_of_file_descriptors = pytest.mark.forked(
test_high_number_of_file_descriptors,
)


@pytest.fixture
def _garbage_bin():
"""Disable garbage collection when this fixture is in use."""
Expand Down
9 changes: 3 additions & 6 deletions requirements/tests.in
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,15 @@ pypytools

pytest-clarity
pytest-cov==2.12.0
pytest-forked>=1.2.0; sys_platform != "win32"
pytest-mock>=1.11.0
pytest-rerunfailures
pytest-sugar>=0.9.3
pytest-watch==4.2.0
pytest-xdist>=1.28.0

# pytest-forked is currently incompatible with pytest 7
# Refs:
# * https://github.com/cherrypy/cheroot/issues/511
# * https://github.com/pytest-dev/pytest-forked/issues/67
pytest >= 4.6.6, < 7
# pytest 7.2 introduces deprecations triggered by pytest-cov
# * https://github.com/cherrypy/cheroot/issues/682
pytest >= 7, <7.2

# HTTP over UNIX socket
requests-unixsocket
Expand Down

0 comments on commit b9a1e28

Please sign in to comment.