diff --git a/spec/oga/xpath/evaluator/axes/self_spec.rb b/spec/oga/xpath/evaluator/axes/self_spec.rb index 164541c..346bb4e 100644 --- a/spec/oga/xpath/evaluator/axes/self_spec.rb +++ b/spec/oga/xpath/evaluator/axes/self_spec.rb @@ -26,5 +26,17 @@ describe Oga::XPath::Evaluator do it_behaves_like :empty_node_set end + + context 'matching the context node itself using the short form' do + before do + @set = @evaluator.evaluate('a/.') + end + + it_behaves_like :node_set, :length => 1 + + example 'return the node' do + @set[0].should == @document.children[0] + end + end end end