Skip to content

[self-tests] fail against pytest 9 #1549

@stanislavlevin

Description

@stanislavlevin

Tests collection fails against pytest 9:

==================================== ERRORS ====================================
________________________ ERROR collecting tests/shells _________________________
/usr/lib64/python3.13/importlib/__init__.py:88: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
<frozen importlib._bootstrap>:1387: in _gcd_import
    ???
<frozen importlib._bootstrap>:1360: in _find_and_load
    ???
<frozen importlib._bootstrap>:1331: in _find_and_load_unlocked
    ???
<frozen importlib._bootstrap>:935: in _load_unlocked
    ???
/usr/lib/python3/site-packages/_pytest/assertion/rewrite.py:197: in exec_module
    exec(co, module.__dict__)
tests/shells/conftest.py:14: in <module>
    @pytest.fixture
     ^^^^^^^^^^^^^^
/usr/lib/python3/site-packages/_pytest/fixtures.py:1399: in fixture
    return fixture_marker(fixture_function)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/usr/lib/python3/site-packages/_pytest/fixtures.py:1239: in __call__
    warnings.warn(MARKED_FIXTURE, stacklevel=2)
E   pytest.PytestRemovedIn9Warning: Marks applied to fixtures have no effect
E   See docs: https://docs.pytest.org/en/stable/deprecations.html#applying-a-mark-to-a-fixture-function

https://docs.pytest.org/en/stable/deprecations.html#applying-a-mark-to-a-fixture-function

Applying a mark to a fixture function never had any effect, but it is a common user error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions