ruby-changes:39369
From: nobu <ko1@a...>
Date: Thu, 30 Jul 2015 16:56:54 +0900 (JST)
Subject: [ruby-changes:39369] nobu:r51450 (trunk): test_settracefunc.rb: refine
nobu 2015-07-30 16:56:20 +0900 (Thu, 30 Jul 2015) New Revision: 51450 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=51450 Log: test_settracefunc.rb: refine * test/ruby/test_settracefunc.rb (test_isolated_raise_in_trace): check outputs. * test/ruby/test_settracefunc.rb (test_recursive): method name which is internally called by TracePoint is now skipped. Modified files: trunk/test/ruby/test_settracefunc.rb Index: test/ruby/test_settracefunc.rb =================================================================== --- test/ruby/test_settracefunc.rb (revision 51449) +++ test/ruby/test_settracefunc.rb (revision 51450) @@ -1040,7 +1040,7 @@ class TestSetTraceFunc < Test::Unit::Tes https://github.com/ruby/ruby/blob/trunk/test/ruby/test_settracefunc.rb#L1040 def test_isolated_raise_in_trace bug9088 = '[ruby-dev:47793] [Bug #9088]' - assert_ruby_status([], <<-END, bug9088) + assert_in_out_err([], <<-END, [], [], bug9088) set_trace_func proc {raise rescue nil} 1.times {break} END @@ -1212,16 +1212,13 @@ class TestSetTraceFunc < Test::Unit::Tes https://github.com/ruby/ruby/blob/trunk/test/ruby/test_settracefunc.rb#L1212 end def test_recursive - assert_ruby_status [], %q{ - stack = [] + assert_in_out_err([], %q{\ TracePoint.new(:c_call){|tp| - p 2 - stack << tp.method_id + p tp.method_id }.enable{ p 1 } - raise if stack != [:p, :hash, :inspect] - }, '[Bug #9940]' + }, %w[:p :inspect 1], [], '[Bug #9940]') end def method_prefix event -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/