Skip to content

Bump to pytest 7.2.0 #438

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Nov 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
Changelog
=========

UNRELEASED
=================
- Replaced usage of deprecated ``@pytest.mark.tryfirst`` with ``@pytest.hookimpl(tryfirst=True)`` `#438 <https://github.com/pytest-dev/pytest-asyncio/pull/438>`_

0.20.1 (22-10-21)
=================
- Fixes an issue that warned about using an old version of pytest, even though the most recent version was installed. `#430 <https://github.com/pytest-dev/pytest-asyncio/issues/430>`_
Expand Down
4 changes: 2 additions & 2 deletions dependencies/default/constraints.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
async-generator==1.10
attrs==22.1.0
coverage==6.5.0
exceptiongroup==1.0.0
flaky==3.7.0
hypothesis==6.56.4
idna==3.4
Expand All @@ -11,9 +12,8 @@ mypy-extensions==0.4.3
outcome==1.2.0
packaging==21.3
pluggy==1.0.0
py==1.11.0
pyparsing==3.0.9
pytest==7.1.3
pytest==7.2.0
pytest-trio==0.7.0
sniffio==1.3.0
sortedcontainers==2.4.0
Expand Down
4 changes: 2 additions & 2 deletions pytest_asyncio/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def pytest_configure(config: Config) -> None:
)


@pytest.mark.tryfirst
@pytest.hookimpl(tryfirst=True)
def pytest_report_header(config: Config) -> List[str]:
"""Add asyncio config to pytest header."""
mode = _get_asyncio_mode(config)
Expand Down Expand Up @@ -299,7 +299,7 @@ async def setup() -> _R:
_HOLDER: Set[FixtureDef] = set()


@pytest.mark.tryfirst
@pytest.hookimpl(tryfirst=True)
def pytest_pycollect_makeitem(
collector: Union[pytest.Module, pytest.Class], name: str, obj: object
) -> Union[
Expand Down
1 change: 0 additions & 1 deletion tests/test_simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,6 @@ async def test_no_warning_on_skip():

def test_async_close_loop(event_loop):
event_loop.close()
return "ok"


def test_warn_asyncio_marker_for_regular_func(testdir):
Expand Down