Skip to content

Commit ae721f9

Browse files
committed
Fix mypy
1 parent 8835e3a commit ae721f9

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/pytest_bdd/gherkin_parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ def from_dict(cls, data: dict[str, Any]) -> Self:
128128
location=Location.from_dict(data["location"]), rows=[Row.from_dict(row) for row in data.get("rows", [])]
129129
)
130130

131-
def transpose(self) -> Self:
131+
def transpose(self) -> DataTable:
132132
# Transpose the cells, turning rows into columns
133133
if not self.rows:
134134
return self # Return itself if there are no rows to transpose

src/pytest_bdd/steps.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ def _(article):
4545
import pytest
4646
from typing_extensions import ParamSpec
4747

48+
from .gherkin_parser import DataTable
4849
from .parser import Step
4950
from .parsers import StepParser, get_parser
5051
from .types import GIVEN, THEN, WHEN
@@ -67,6 +68,7 @@ class StepFunctionContext:
6768
parser: StepParser
6869
converters: dict[str, Callable[[str], Any]] = field(default_factory=dict)
6970
target_fixture: str | None = None
71+
data_table: DataTable | None = None
7072

7173

7274
def get_step_fixture_name(step: Step) -> str:

0 commit comments

Comments
 (0)