There are two kind of benchmarks:
n
Here are some ideas for the API:
Prefer.session do |b| b.iterations 'File.stat' do File.stat(Dir.tmpdir) end b.bench 'Array#sort' do |n| ary = Array.new(n) { rand(n) } b.measure do ary.sort end end end
There was an error while loading. Please reload this page.