Namespaced benchmarks per parser category.

This commit is contained in:
Yorick Peterse 2014-06-13 00:25:39 +02:00
parent f557aaef76
commit 61d553be34
15 changed files with 15 additions and 15 deletions

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
measure_average do measure_average do
Oga::XML::Lexer.new(big_xml_file).advance { } Oga::XML::Lexer.new(big_xml_file).advance { }

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
Benchmark.bmbm(10) do |bench| Benchmark.bmbm(10) do |bench|
bench.report '10MB of XML using IO' do bench.report '10MB of XML using IO' do

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
string = 'Hello, how are you doing today?' string = 'Hello, how are you doing today?'
small = "<![CDATA[#{string}]]>" small = "<![CDATA[#{string}]]>"

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
simple = '<p>Hello world</p>' simple = '<p>Hello world</p>'
attributes = '<p class="foo">Hello world</p>' attributes = '<p class="foo">Hello world</p>'

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
html = read_html html = read_html

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
html = read_html html = read_html

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml
lines = xml.lines.count lines = xml.lines.count

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml
parser = Oga::XML::Parser.new(xml) parser = Oga::XML::Parser.new(xml)

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
simple = '<p>Hello world</p>' simple = '<p>Hello world</p>'
attributes = '<p class="foo">Hello world</p>' attributes = '<p class="foo">Hello world</p>'

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
html = read_html html = read_html

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml

View File

@ -1,4 +1,4 @@
require_relative '../benchmark_helper' require_relative '../../benchmark_helper'
xml = read_big_xml xml = read_big_xml
parser = Oga::XML::PullParser.new(xml) parser = Oga::XML::PullParser.new(xml)