diff options
Diffstat (limited to 'benchmark/bm_app_erb.rb')
-rw-r--r-- | benchmark/bm_app_erb.rb | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/benchmark/bm_app_erb.rb b/benchmark/bm_app_erb.rb index 77c66a7949..9a1cb2707f 100644 --- a/benchmark/bm_app_erb.rb +++ b/benchmark/bm_app_erb.rb @@ -4,17 +4,7 @@ require 'erb' -data = DATA.read -max = 15_000 -title = "hello world!" -content = "hello world!\n" * 10 - -max.times{ - ERB.new(data).result(binding) -} - -__END__ - +data = <<erb <html> <head> <%= title %> </head> <body> @@ -24,3 +14,12 @@ __END__ </p> </body> </html> +erb + +max = 15_000 +title = "hello world!" +content = "hello world!\n" * 10 + +max.times{ + ERB.new(data).result(binding) +} |