godog icon indicating copy to clipboard operation
godog copied to clipboard

Skip undefined steps in after scenario hooks

Open vearutop opened this issue 2 years ago • 2 comments

🤔 What's changed?

After scenario hooks will no be invoked after non-last undefined step.

⚡️ What's your motivation?

Originally, undefined steps that were in the middle of scenario would invoke s.runAfterScenarioHooks and then proceed to next steps. This may result in multiple invocations of after scenario hooks which is incorrect behavior.

🏷️ What kind of change is this?

  • :bug: Bug fix (non-breaking change which fixes a defect)

♻️ Anything particular you want feedback on?

📋 Checklist:

  • [x] I agree to respect and uphold the Cucumber Community Code of Conduct
  • [ ] I've changed the behaviour of the code
    • [ ] I have added/updated tests to cover my changes.
  • [ ] My change requires a change to the documentation.
    • [ ] I have updated the documentation accordingly.
  • [x] Users should know about my change
    • [x] I have added an entry to the "Unreleased" section of the CHANGELOG, linking to this pull request.

This text was originally generated from a template, then edited by hand. You can modify the template here.

vearutop avatar Aug 09 '22 11:08 vearutop

Codecov Report

Merging #494 (e158c25) into main (fd5b6a1) will not change coverage. The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main     #494   +/-   ##
=======================================
  Coverage   81.69%   81.69%           
=======================================
  Files          27       27           
  Lines        2267     2267           
=======================================
  Hits         1852     1852           
  Misses        316      316           
  Partials       99       99           
Impacted Files Coverage Δ
suite.go 87.61% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

codecov[bot] avatar Aug 09 '22 11:08 codecov[bot]

Go API Changes

# github.com/cucumber/godog
## compatible changes
Feature: added

# summary
Inferred base version: v0.12.5
Suggested version: v0.13.0

github-actions[bot] avatar Aug 09 '22 14:08 github-actions[bot]