diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-01-23 11:19:58 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-01-23 11:19:58 +0000 |
commit | f061bec852cae077b529790a12d9c9caed742290 (patch) | |
tree | 77003ff9d0c1abc03c641f38d7a9cebc289fc7b1 /test | |
parent | f614957d120f9c2ea7bb1991429ea15011ba858c (diff) | |
download | ruby-f061bec852cae077b529790a12d9c9caed742290.tar.gz |
* test/ruby/test_settracefunc.rb: check the target thread.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_settracefunc.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/test_settracefunc.rb b/test/ruby/test_settracefunc.rb index e1f01315e5..70a2be6a50 100644 --- a/test/ruby/test_settracefunc.rb +++ b/test/ruby/test_settracefunc.rb @@ -1074,6 +1074,7 @@ class TestSetTraceFunc < Test::Unit::TestCase events = [] assert !defined?(MISSING_CONSTANT_59398) TracePoint.new(:c_call, :c_return, :call, :return){|tp| + next if !target_thread? next unless tp.defined_class == Module # rake/ext/module.rb aliases :const_missing and Ruby uses the aliased name # but this only happens when running the full test suite @@ -1104,6 +1105,7 @@ class TestSetTraceFunc < Test::Unit::TestCase events = [] aliased = AliasedRubyMethod.new TracePoint.new(:call, :return){|tp| + next if !target_thread? events << [tp.event, tp.method_id] }.enable{ aliased.bar @@ -1122,6 +1124,7 @@ class TestSetTraceFunc < Test::Unit::TestCase events = [] aliased = AliasedCMethod.new TracePoint.new(:call, :return, :c_call, :c_return){|tp| + next if !target_thread? events << [tp.event, tp.method_id] }.enable{ aliased.size @@ -1139,6 +1142,7 @@ class TestSetTraceFunc < Test::Unit::TestCase events = [] assert !respond_to?(:missing_method_59398) TracePoint.new(:c_call, :c_return, :call, :return){|tp| + next if !target_thread? next unless tp.defined_class == BasicObject # rake/ext/module.rb aliases :const_missing and Ruby uses the aliased name # but this only happens when running the full test suite |