Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SIGINT trap consistent with TERM behaviour #1353

Merged
merged 1 commit into from
May 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ Please visit [cucumber/CONTRIBUTING.md](https://github.com/cucumber/cucumber/blo
* Fix seed printed in cucumber UI to match the seed that was actually used.
([#1329](https://github.com/cucumber/cucumber-ruby/pull/1329)
[deivid-rodriguez](https://github.com/deivid-rodriguez))
* Make SIGINT/`Ctrl+c` behavior consistent with SIGTERM/`kill` behavior - now first invocation causes existing scenario to stop running and jump to `at_exit`, second invocation causes immediate exit. Before that first invocation only instructed Cucumber to exit after scenario and second invocation caused immediate exit skipping `at_exit`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tiny formatting detail: if you remove the newline at line 28, the bullet list becomes 1 bullet list, making formatting nicer.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just git commit amend this @akostadinov and I'll approve and merge this in.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't notice that! fixed now

([#1353](https://github.com/cucumber/cucumber-ruby/pull/1353)
[akostadinov](https://github.com/akostadinov))

### Added

Expand Down
1 change: 1 addition & 0 deletions lib/cucumber/cli/main.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ def trap_interrupt
exit_unable_to_finish! if Cucumber.wants_to_quit
Cucumber.wants_to_quit = true
STDERR.puts "\nExiting... Interrupt again to exit immediately."
exit_unable_to_finish
end
end

Expand Down