Sha256: 38cca45bf77b15b1278cef5a48cc28cc2b77930782b006655c5d69d7643655d7
Contents?: true
Size: 603 Bytes
Versions: 18
Compression:
Stored size: 603 Bytes
Contents
describe Rake::Funnel::Extensions::REXML::Functions do let(:xml) { <<EOF <editors xmlns="http://example.com"> <editor id="emacs">EMACS</editor> <editor id="vi">VIM</editor> <editor id="notepad">Notepad</editor> </editors> EOF } subject { REXML::Document.new(xml) } it 'should support lower-case function' do expect(REXML::XPath.match(subject, "//editor[lower-case(text())='vim']").first.to_s).to match(/VIM/) end it 'should support matches function' do expect(REXML::XPath.match(subject, "//editor[matches(@id, '*pad')]").first.to_s).to match(/Notepad/) end end
Version data entries
18 entries across 18 versions & 1 rubygems