2014-06-12 22:49:24 +00:00
|
|
|
require_relative '../../benchmark_helper'
|
|
|
|
|
|
|
|
xpath = '/wikimedia/projects/project[@name="Wikipedia"]/editions/edition/text()'
|
|
|
|
|
|
|
|
Benchmark.ips do |bench|
|
2014-06-23 18:49:11 +00:00
|
|
|
bench.report 'Wikipedia example' do
|
|
|
|
Oga::XPath::Lexer.new(xpath).advance { }
|
2014-06-12 22:49:24 +00:00
|
|
|
end
|
|
|
|
end
|