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

test_gc.rb: fix failure message

* test/ruby/test_gc.rb (test_interrupt_in_finalizer): append
  signal info to stderr outputs in a proc, not to a proc.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2015-10-30 02:31:38 +00:00
parent bb87df3ef1
commit fc8416abe7

View file

@ -333,9 +333,9 @@ class TestGc < Test::Unit::TestCase
def get_signal_info
if RUBY_PLATFORM.include?('solaris')
`/usr/bin/psig #{$$}`
"\n"+`/usr/bin/psig #{$$}`
elsif File.exist?('/proc/self/status')
IO.read('/proc/self/status')
"\n"+IO.read('/proc/self/status')
else
''
end
@ -364,7 +364,7 @@ class TestGc < Test::Unit::TestCase
unless /mswin|mingw/ =~ RUBY_PLATFORM
assert_equal("INT", Signal.signame(status.termsig), bug10595)
end
assert_match(/Interrupt/, err.first, proc {err.join("\n")}+get_signal_info)
assert_match(/Interrupt/, err.first, proc {err.join("\n")+get_signal_info})
assert_empty(out)
end