Rakefile in faml-0.2.8 vs Rakefile in faml-0.2.9

- old
+ new

@@ -8,26 +8,43 @@ end require 'rspec/core/rake_task' RSpec::Core::RakeTask.new(:spec) +task :benchmark => ['benchmark:rendering', 'benchmark:compiling'] + namespace :benchmark do task :rendering => ['benchmark:rendering:haml', 'benchmark:rendering:attributes', 'benchmark:rendering:slim'] namespace :rendering do - desc "Run benchmark with Haml's standard template" + desc "Run rendering benchmark with Haml's standard template" task :haml do haml_gem = Gem::Specification.find_by_name('haml') standard_haml_path = File.join(haml_gem.gem_dir, 'test', 'templates', 'standard.haml') sh 'ruby', 'benchmark/rendering.rb', standard_haml_path end - desc "Run benchmark for attribute builder" + desc "Run rendering benchmark for attribute builder" task :attributes do sh 'ruby', 'benchmark/rendering.rb', 'benchmark/attribute_builder.haml', 'benchmark/attribute_builder.slim' end - desc "Run slim's benchmark" + desc "Run slim's rendering benchmark" task :slim do sh 'ruby', 'benchmark/slim.rb' + end + end + + task :compiling => ['benchmark:compiling:haml', 'benchmark:compiling:slim'] + namespace :compiling do + desc "Run compiling benchmark with Haml's standard template" + task :haml do + haml_gem = Gem::Specification.find_by_name('haml') + standard_haml_path = File.join(haml_gem.gem_dir, 'test', 'templates', 'standard.haml') + sh 'ruby', 'benchmark/compiling.rb', standard_haml_path + end + + desc "Run slim's compiling benchmark" + task :slim do + sh 'ruby', 'benchmark/compiling.rb', 'benchmark/view.haml', 'benchmark/view.slim' end end end