Distinguish hash argument and keyword argument in arguments of XML::Querying#xpath
This commit is contained in:
parent
804f755101
commit
b9bcd21b2b
|
@ -19,7 +19,7 @@ describe Oga::XML::Querying do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'evaluates an expression using a variable' do
|
it 'evaluates an expression using a variable' do
|
||||||
expect(@document.xpath('$number', 'number' => 10)).to eq(10)
|
expect(@document.xpath('$number', {'number' => 10})).to eq(10)
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'respects custom namespace aliases' do
|
it 'respects custom namespace aliases' do
|
||||||
|
@ -37,7 +37,7 @@ describe Oga::XML::Querying do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'evaluates an expression using a variable' do
|
it 'evaluates an expression using a variable' do
|
||||||
expect(@document.at_xpath('$number', 'number' => 10)).to eq(10)
|
expect(@document.at_xpath('$number', {'number' => 10})).to eq(10)
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'respects custom namespace aliases' do
|
it 'respects custom namespace aliases' do
|
||||||
|
|
Loading…
Reference in New Issue