Skip to content

Commit afec8b1

Browse files
committed
Add back comment that was relevant
1 parent 5e10d34 commit afec8b1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/pytest_bdd/scenario.py

+2
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,8 @@ def _execute_step_function(
235235

236236
request.config.hook.pytest_bdd_before_step_call(**kw)
237237

238+
# Execute the step as if it was a pytest fixture using `call_fixture_func`,
239+
# so that we can allow "yield" statements in it
238240
return_value = call_fixture_func(fixturefunc=context.step_func, request=request, kwargs=kwargs)
239241

240242
except Exception as exception:

0 commit comments

Comments
 (0)