From 6e2be785468ee5914208355012b87ddd67fbf401 Mon Sep 17 00:00:00 2001 From: Yorick Peterse Date: Fri, 25 Jul 2014 00:49:13 +0200 Subject: [PATCH] Rewrote context names of some XPath specs. --- spec/oga/xpath/evaluator/axes/ancestor_or_self_spec.rb | 4 ++-- spec/oga/xpath/evaluator/axes/ancestor_spec.rb | 4 ++-- spec/oga/xpath/evaluator/axes/attribute_spec.rb | 2 +- spec/oga/xpath/evaluator/axes/child_spec.rb | 6 +++--- spec/oga/xpath/evaluator/axes/descendant_spec.rb | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/spec/oga/xpath/evaluator/axes/ancestor_or_self_spec.rb b/spec/oga/xpath/evaluator/axes/ancestor_or_self_spec.rb index 55456a2..4f8f2b9 100644 --- a/spec/oga/xpath/evaluator/axes/ancestor_or_self_spec.rb +++ b/spec/oga/xpath/evaluator/axes/ancestor_or_self_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe Oga::XPath::Evaluator do context 'ancestor-or-self axis' do before do - @document = parse('') + @document = parse('') @c_node = @document.children[0].children[0].children[0] @evaluator = described_class.new(@c_node) end @@ -32,7 +32,7 @@ describe Oga::XPath::Evaluator do end end - context 'missing ancestors' do + context 'ancestors that only match the context nodes' do before do @set = @evaluator.evaluate('ancestor-or-self::c') end diff --git a/spec/oga/xpath/evaluator/axes/ancestor_spec.rb b/spec/oga/xpath/evaluator/axes/ancestor_spec.rb index 9dfde95..13e831b 100644 --- a/spec/oga/xpath/evaluator/axes/ancestor_spec.rb +++ b/spec/oga/xpath/evaluator/axes/ancestor_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe Oga::XPath::Evaluator do context 'ancestor axis' do before do - @document = parse('') + @document = parse('') @c_node = @document.children[0].children[0].children[0] @evaluator = described_class.new(@c_node) end @@ -32,7 +32,7 @@ describe Oga::XPath::Evaluator do end end - context 'missing ancestors' do + context 'non existing ancestors' do before do @set = @evaluator.evaluate('ancestor::foobar') end diff --git a/spec/oga/xpath/evaluator/axes/attribute_spec.rb b/spec/oga/xpath/evaluator/axes/attribute_spec.rb index a709837..2aa096d 100644 --- a/spec/oga/xpath/evaluator/axes/attribute_spec.rb +++ b/spec/oga/xpath/evaluator/axes/attribute_spec.rb @@ -39,7 +39,7 @@ describe Oga::XPath::Evaluator do end end - context 'missing attributes' do + context 'non existing attributes' do before do @set = @evaluator.evaluate('attribute::bar') end diff --git a/spec/oga/xpath/evaluator/axes/child_spec.rb b/spec/oga/xpath/evaluator/axes/child_spec.rb index cac27ec..25efae0 100644 --- a/spec/oga/xpath/evaluator/axes/child_spec.rb +++ b/spec/oga/xpath/evaluator/axes/child_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe Oga::XPath::Evaluator do context 'child axis' do before do - @document = parse('') + @document = parse('') @evaluator = described_class.new(@document) end @@ -31,9 +31,9 @@ describe Oga::XPath::Evaluator do end end - context 'invalid children' do + context 'non existing children' do before do - @set = @evaluator.evaluate('child::foobar') + @set = @evaluator.evaluate('child::b') end it_behaves_like :empty_node_set diff --git a/spec/oga/xpath/evaluator/axes/descendant_spec.rb b/spec/oga/xpath/evaluator/axes/descendant_spec.rb index d483f5e..bb026d0 100644 --- a/spec/oga/xpath/evaluator/axes/descendant_spec.rb +++ b/spec/oga/xpath/evaluator/axes/descendant_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe Oga::XPath::Evaluator do context 'descendant axis' do before do - @document = parse('') + @document = parse('') @evaluator = described_class.new(@document) @first_a = @document.children[0] @@ -50,7 +50,7 @@ describe Oga::XPath::Evaluator do end end - context 'invalid descendants' do + context 'non existing descendants' do before do @set = @evaluator.evaluate('descendant::foobar') end