man-group / man-group/pytest-plugins

1.7.0 fixture-config: pytest warnings

Open
#178 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
597
Forks
89
PR merge metrics
No merged PRs in 30d

Description

```console
+ /usr/bin/python3 -Bm pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.9, pytest-6.2.3, py-1.10.0, pluggy-0.13.1
rootdir: /home/tkloczko/rpmbuild/BUILD/pytest-fixture-config-1.7.0, configfile: setup.cfg
plugins: forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, asyncio-0.14.0, expect-1.1.0, cov-2.11.1, httpbin-1.0.0, xdist-2.2.1, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, pyfakefs-4.4.0, freezegun-0.4.2, cases-3.4.6, hypothesis-6.10.1, case-1.5.3, isort-1.3.0, aspectlib-1.5.2, flaky-3.7.0, mock-3.6.0
collected 5 items

tests/unit/test_fixture_config.py .s.s. [100%]

============================================================================= warnings summary =============================================================================
tests/unit/test_fixture_config.py:52
/home/tkloczko/rpmbuild/BUILD/pytest-fixture-config-1.7.0/tests/unit/test_fixture_config.py:52: PytestDeprecationWarning: @pytest.yield_fixture is deprecated.
Use @pytest.fixture instead; they are the same.
def yet_another_fixture():

tests/unit/test_fixture_config.py:63
/home/tkloczko/rpmbuild/BUILD/pytest-fixture-config-1.7.0/tests/unit/test_fixture_config.py:63: PytestDeprecationWarning: @pytest.yield_fixture is deprecated.
Use @pytest.fixture instead; they are the same.
def yet_some_other_fixture():

-- Docs: https://docs.pytest.org/en/stable/warnings.html
========================================================================= short test summary info ==========================================================================
SKIPPED [1] pytest_fixture_config.py:31: config variable foo missing, skipping test
SKIPPED [1] pytest_fixture_config.py:45: config variable foo missing, skipping test
================================================================= 3 passed, 2 skipped, 2 warnings in 0.05s =================================================================
```

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tests/unit/test_fixture_config.py, especially the fixtures at lines 52 and 63 identified in the warning output. Run pytest before and after the change; done means the five tests retain their existing results and the PytestDeprecationWarning entries no longer appear.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing-qa
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.