Created
December 18, 2014 20:04
-
-
Save nmeylan/fb323b3b7611b0903fd0 to your computer and use it in GitHub Desktop.
Ruby benchmark template
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'Benchmark' | |
ITERATION = 100_000 | |
Benchmark.bm(27) do |bm| | |
bm.report('TEST 1') do | |
ITERATION.times do | |
# test 1 content | |
end | |
end | |
bm.report('TEST 2') do | |
ITERATION.times do | |
# test 2 content | |
end | |
end | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment