Skip to content
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: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ repos:
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "c60c980e561ed3e73101667fe8365c609d19a438" # frozen: v0.15.9
rev: "c59bba8fb259db0fec2bbb77ad8ba51ea7341b56" # frozen: v0.15.20
hooks:
- id: ruff
args: [ --fix ]
- id: ruff-format
- repo: https://github.com/python-poetry/poetry
rev: "a84cd0f1bedb5769ef6ef7389d8ee99b93b9ba4c" # frozen: 2.3.2
rev: "811a12dae0fe81f199e3f1b88b8b8be9eed543c2" # frozen: 2.4.1
hooks:
- id: poetry-check
args: ["--lock"]
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ Added
Changed
+++++++
* Relaxed `gherkin-official` dependency requirement to `>=29.0.0` to allow for newer versions of the `gherkin-official` package.
* Excluded `gherkin-official` `31.0.0` and `32.0.0`, which crash with ``StopIteration`` when parsing empty descriptions (fixed upstream in `32.0.1`).

Deprecated
++++++++++
Expand Down
2 changes: 1 addition & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ dependencies = [
"pytest>=7.0.0",
"typing-extensions",
"packaging",
"gherkin-official>=29.0.0",
# 31.0.0 and 32.0.0 crash with StopIteration on empty descriptions (fixed in 32.0.1)
"gherkin-official>=29.0.0,!=31.0.0,!=32.0.0",
]

[project.urls]
Expand Down
2 changes: 1 addition & 1 deletion tests/parser/test_errors.py

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look like this commit changed the way gherkin works: cucumber/gherkin@93339df 'Feature:' is consumed as description text instead of raising the "got 'Given'" parse error so pytest-bdd's FeatureError no longer fire.

Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ def test_step_outside_scenario_or_background_error(pytester):
features.joinpath("test.feature").write_text(
textwrap.dedent(
"""
Feature: Invalid Feature
# Step not inside a scenario or background
Given a step that is not inside a scenario or background

Feature: Invalid Feature
Scenario: A valid scenario
Given a step inside a scenario

Expand Down
5 changes: 2 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tox]
envlist = py{3.9,3.10,3.11}-pytest{7.0,7.1,7.2,7.3,7.4,8.0,8.1,8.2,8.3,latest}-gherkin_official{29,30,31,32,33,34,35,36,37,latest}-coverage
py{3.12,3.13,3.14}-pytest{7.3,7.4,8.0,8.1,8.2,8.3,latest}-gherkin_official{29,30,31,32,33,34,35,36,37,latest}-coverage
envlist = py{3.9,3.10,3.11}-pytest{7.0,7.1,7.2,7.3,7.4,8.0,8.1,8.2,8.3,latest}-gherkin_official{29,30,32,33,34,35,36,37,latest}-coverage
py{3.12,3.13,3.14}-pytest{7.3,7.4,8.0,8.1,8.2,8.3,latest}-gherkin_official{29,30,32,33,34,35,36,37,latest}-coverage
py3.12-pytestlatest-xdist-coverage
mypy

Expand All @@ -17,7 +17,6 @@ deps =
gherkin_official34: gherkin-official~=34.0.0
gherkin_official33: gherkin-official~=33.0.0
gherkin_official32: gherkin-official~=32.0.0
gherkin_official31: gherkin-official~=31.0.0
gherkin_official30: gherkin-official~=30.0.0
gherkin_official29: gherkin-official~=29.0.0

Expand Down
Loading