Page MenuHomeFreeBSD

pytest: Silence deprecation warning
ClosedPublic

Authored by jlduran on Dec 27 2022, 9:35 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Mar 30, 1:20 AM
Unknown Object (File)
Mon, Mar 30, 1:20 AM
Unknown Object (File)
Sat, Mar 28, 1:42 AM
Unknown Object (File)
Fri, Mar 27, 9:25 AM
Unknown Object (File)
Sat, Mar 21, 1:34 PM
Unknown Object (File)
Wed, Mar 11, 5:19 AM
Unknown Object (File)
Feb 7 2026, 7:14 PM
Unknown Object (File)
Feb 7 2026, 7:09 PM

Details

Summary

Before pluggy, pytest’s plugin library, was its own package and had a clear API, pytest just used pytest.mark to configure hooks.

The pytest.hookimpl() and pytest.hookspec() decorators have been available since years and should be used instead.

Reference: https://docs.pytest.org/en/latest/deprecations.html#configuring-hook-specs-impls-using-markers

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable