Permalink
Browse files

Update performance profiler to work with latest ruby-prof

  • Loading branch information...
arunagw committed May 11, 2012
1 parent 62f098d commit 9d616ea360b439b9204c68748553ebb00ce7ef90
Showing with 2 additions and 2 deletions.
  1. +1 −1 Gemfile
  2. +1 −1 activesupport/lib/active_support/testing/performance/ruby.rb
View
@@ -47,7 +47,7 @@ instance_eval File.read '.Gemfile' if File.exists? '.Gemfile'
platforms :mri do
group :test do
- gem 'ruby-prof', '0.10.8' if RUBY_VERSION < '1.9.3'
+ gem 'ruby-prof', '~> 0.11.2' if RUBY_VERSION < '1.9.3'
end
end
@@ -36,7 +36,7 @@ def run
RubyProf.pause
full_profile_options[:runs].to_i.times { run_test(@metric, :profile) }
@data = RubyProf.stop
- @total = @data.threads.values.sum(0) { |method_infos| method_infos.max.total_time }
+ @total = @data.threads.sum(0) { |thread| thread.methods.max.total_time }
end
def record

0 comments on commit 9d616ea

Please sign in to comment.