File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -125,20 +125,17 @@ def _step_decorator(
125
125
converters = {}
126
126
127
127
def decorator (func : TCallable ) -> TCallable :
128
- step_func = func
129
128
parser_instance = get_parser (step_name )
130
129
parsed_step_name = parser_instance .name
131
130
132
- # TODO: Try to not attach to both step_func and lazy_step_func
133
-
134
131
def lazy_step_func () -> TCallable :
135
- return step_func
132
+ return func
136
133
137
134
lazy_step_func ._pytest_bdd_parser = parser_instance
138
135
139
- setdefault (step_func , "_pytest_bdd_parsers" , []).append (parser_instance )
140
- step_func ._pytest_bdd_converters = converters
141
- step_func ._pytest_bdd_target_fixture = target_fixture
136
+ setdefault (func , "_pytest_bdd_parsers" , []).append (parser_instance )
137
+ func ._pytest_bdd_converters = converters
138
+ func ._pytest_bdd_target_fixture = target_fixture
142
139
143
140
fixture_step_name = get_step_fixture_name (parsed_step_name , step_type )
144
141
You can’t perform that action at this time.
0 commit comments