pytest-dev / pytest-dev/pytest-bdd
Cucumber JSON report is generated without skipped tests info
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.5k
- Forks
- 251
- Avg merge
- 43m
- Merged PRs (30d)
- 2
Description
Environment:
platform darwin -- Python 3.9.12, pytest-7.1.2, pluggy-1.0.0
plugins: splinter-3.3.2, bdd-6.0.1, clarity-1.0.1
Steps to reproduce:
- Create simple pytest-bdd setup with feature file and tests.
- In feature file and default @skip flag like this:
@skip
Scenario: Test1
When blabla
Then blablabla
Or any other way to skip test execution - Run pytest with
addopts = -vv -rsfx --cucumber-json=cucumber_report.json --gherkin-terminal-reporter --color=yesin pytest.ini or same alternative in CLI - Gherkin terminal output will contain
test_bla.py::test_bla <- venv/lib/python3.9/site-packages/pytest_bdd/scenario.py SKIPPED (unconditional skip)
Actual result:
5. cucumber.json file doesn't contain any info about skipped test at all
Expected result:
5. cucumber.json file contains info about skipped test (at least ..."result": {"status": "skipped"... )
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with a pytest.ini or CLI configuration using --cucumber-json and the gherkin terminal reporter, including an @skip scenario. Trace how skipped pytest-bdd scenarios are represented in the generated Cucumber JSON. Done means the report includes the skipped scenario with a result status of skipped.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100