Sha256: 223fc99065f6a3eb01460ede4682ad56e359c1636ea204b750f11548fb88628b

Contents?: true

Size: 344 Bytes

Versions: 8

Compression:

Stored size: 344 Bytes

Contents

#!/usr/bin/env ruby

require 'test/unit'
require 'ruby-prof'

# --  Test for bug
# http://github.com/rdp/ruby-prof/issues#issue/12

class EnumerableTest < Test::Unit::TestCase
  def test_enumerable
    result = RubyProf.profile do
      3.times {  [1,2,3].any? {|n| n} }
    end
    assert result.threads.to_a.first[1].length == 4    
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
ruby-prof-danielhoey-0.8.1 test/enumerable_test.rb
ruby-prof-0.8.2 test/enumerable_test.rb
ruby-prof-0.8.1-x86-mingw32 test/enumerable_test.rb
ruby-prof-0.8.1-x86-mswin32 test/enumerable_test.rb
ruby-prof-0.8.1 test/enumerable_test.rb
ruby-prof-0.7.10 test/enumerable_test.rb
ruby-prof-0.7.9 test/enumerable_test.rb
ruby-prof-0.7.8 test/enumerable_test.rb