diff --git a/spec/oga/xpath/parser/calls_spec.rb b/spec/oga/xpath/parser/calls_spec.rb index 0e960ce..81356c7 100644 --- a/spec/oga/xpath/parser/calls_spec.rb +++ b/spec/oga/xpath/parser/calls_spec.rb @@ -71,5 +71,13 @@ describe Oga::XPath::Parser do s(:call, 'bar') ) end + + it 'parses a function call inside a predicate' do + parse_xpath('A[foo()]').should == s( + :predicate, + s(:axis, 'child', s(:test, nil, 'A')), + s(:call, 'foo') + ) + end end end