File tree 1 file changed +9
-10
lines changed
1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -73,19 +73,18 @@ def _execute_step_function(
73
73
# Get the step argument values.
74
74
converters = context .converters
75
75
kwargs = {}
76
-
77
- for arg , value in context .parser .parse_arguments (step .name ).items ():
78
- if arg in converters :
79
- value = converters [arg ](value )
80
- kwargs [arg ] = value
81
-
82
76
args = get_args (context .step_func )
83
- kwargs = {arg : kwargs [arg ] if arg in kwargs else request .getfixturevalue (arg ) for arg in args }
84
- kw ["step_func_args" ] = kwargs
85
-
86
- request .config .hook .pytest_bdd_before_step_call (** kw )
87
77
88
78
try :
79
+ for arg , value in context .parser .parse_arguments (step .name ).items ():
80
+ if arg in converters :
81
+ value = converters [arg ](value )
82
+ kwargs [arg ] = value
83
+
84
+ kwargs = {arg : kwargs [arg ] if arg in kwargs else request .getfixturevalue (arg ) for arg in args }
85
+ kw ["step_func_args" ] = kwargs
86
+
87
+ request .config .hook .pytest_bdd_before_step_call (** kw )
89
88
# Execute the step as if it was a pytest fixture, so that we can allow "yield" statements in it
90
89
return_value = call_fixture_func (fixturefunc = context .step_func , request = request , kwargs = kwargs )
91
90
except Exception as exception :
You can’t perform that action at this time.
0 commit comments