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:
parent
bb87df3ef1
commit
fc8416abe7
1 changed files with 3 additions and 3 deletions
|
@ -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
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue