1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

Markaby doesn't support caching. It's not fair to benchmark it as though it did.

git-svn-id: svn://hamptoncatlin.com/haml/trunk@665 7063305b-7217-0410-af8c-cdc13e5119b9
This commit is contained in:
nex3 2007-11-25 01:30:49 +00:00
parent 7397b41603
commit fe7e6117ac

View file

@ -51,12 +51,10 @@ module Haml
erb = ERB.new(erb_template, nil, '-')
obj.instance_eval("def erb; #{erb.src}; end")
Erubis::Eruby.new(erb_template).def_method(obj, :erubis)
mab = Markaby::Template.new(markaby_template)
times = Benchmark.bmbm do |b|
b.report("haml:") { runs.times { obj.haml } }
b.report("erb:") { runs.times { obj.erb } }
b.report("erubis:") { runs.times { obj.erubis } }
b.report("mab:") { runs.times { mab.render } }
end
print_result["ERB", 1]