Skip to content

Commit 51a3c34

Browse files
committed
Remove removing support for py 3.8
1 parent 0efab69 commit 51a3c34

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

python/cucumber_expressions/expression_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def escape(string: str) -> str:
8181
.replace(r"/", "\\/")
8282
)
8383

84-
def create_parameter_type_matchers(self, text) -> list[ParameterTypeMatcher]:
84+
def create_parameter_type_matchers(self, text) -> List[ParameterTypeMatcher]:
8585
parameter_type_matchers = []
8686
for parameter_type in self.parameter_type_registry.parameter_types:
8787
if parameter_type.use_for_snippets:

python/cucumber_expressions/regular_expression.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import re
22
from collections.abc import Generator
3-
from typing import Optional, Union, Tuple
3+
from typing import Optional, Union, Tuple, List
44

55
from cucumber_expressions.argument import Argument
66
from cucumber_expressions.parameter_type import ParameterType
@@ -32,7 +32,7 @@ def __init__(
3232
self.parameter_type_registry = parameter_type_registry
3333
self.tree_regexp: TreeRegexp = TreeRegexp(self.expression_regexp.pattern)
3434

35-
def match(self, text) -> Optional[list[Argument]]:
35+
def match(self, text) -> Optional[List[Argument]]:
3636
# Convert the generator to a list before passing it to Argument.build
3737
parameter_types_and_names = list(
3838
(parameter_type, capture_name)

python/tests/test_expression.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from decimal import Decimal
22
from pathlib import Path
3-
from typing import Optional, Any
3+
from typing import Optional, Any, Tuple
44

55
from tests.definitions import TESTDATA_ROOT_DIR
66

@@ -20,7 +20,7 @@ def match(
2020
expression: str,
2121
match_text: str,
2222
parameter_registry: ParameterTypeRegistry = ParameterTypeRegistry(),
23-
) -> Optional[tuple[Any, str]]:
23+
) -> Optional[Tuple[Any, str]]:
2424
cucumber_expression = CucumberExpression(expression, parameter_registry)
2525
matches = cucumber_expression.match(match_text)
2626

0 commit comments

Comments
 (0)