Files
liquid/performance/benchmark.rb
Tobias Lütke 05d9976e16 fix benchmark
2012-10-29 16:47:57 -04:00

12 lines
262 B
Ruby

require 'rubygems'
require 'benchmark'
require File.dirname(__FILE__) + '/theme_runner'
profiler = ThemeRunner.new
Benchmark.bmbm do |x|
x.report("parse:") { 100.times { profiler.compile } }
x.report("parse & run:") { 100.times { profiler.run } }
end