1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

test_beginendblock.rb, test_signal.rb: run with default handler

* test/ruby/test_beginendblock.rb (test_propagate_signaled): run
  with default handler.

* test/ruby/test_signal.rb (test_hup_me): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45891 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2014-05-09 15:13:11 +00:00
parent ed37579c6a
commit a738b98fc6
2 changed files with 4 additions and 0 deletions

View file

@ -112,6 +112,7 @@ EOW
ruby = EnvUtil.rubybin
out = IO.popen(
[ruby,
'-e', 'trap(:INT, "DEFAULT")',
'-e', 'STDERR.reopen(STDOUT)',
'-e', 'at_exit{Process.kill(:INT, $$); sleep 5 }']) {|f|
timeout(10) {

View file

@ -256,9 +256,12 @@ EOS
# that signal will be deliverd synchronously.
# This ugly workaround was introduced to don't break
# compatibility against silly example codes.
assert_separately(<<-RUBY)
trap(:HUP, "DEFAULT")
assert_raise(SignalException) {
Process.kill('HUP', Process.pid)
}
RUBY
bug8137 = '[ruby-dev:47182] [Bug #8137]'
assert_nothing_raised(bug8137) {
Timeout.timeout(1) {