mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
runner.rb: check increment
* test/runner.rb (after_teardown): check increment of active trace events. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
261aaedd73
commit
045b6e9fb9
1 changed files with 3 additions and 1 deletions
|
@ -24,8 +24,10 @@ module Test::Unit
|
||||||
assert_empty(Process.waitall)
|
assert_empty(Process.waitall)
|
||||||
|
|
||||||
# detect zombie traces.
|
# detect zombie traces.
|
||||||
|
zombie_traces = Hash.new(0)
|
||||||
TracePoint.stat.each{|key, (activated, deleted)|
|
TracePoint.stat.each{|key, (activated, deleted)|
|
||||||
assert_equal(0, activated, "The number of active trace events (#{key}) should be zero.")
|
old, zombie_traces[key] = zombie_traces[key], activated
|
||||||
|
assert_equal(old, activated, "The number of active trace events (#{key}) should not increase.")
|
||||||
# puts "TracePoint - deleted: #{deleted}" if deleted > 0
|
# puts "TracePoint - deleted: #{deleted}" if deleted > 0
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue