Sha256: d8f6e80f368f8287eca379bdf40bd1d289c0470432020c1df64e197299b166e7
Contents?: true
Size: 623 Bytes
Versions: 11
Compression:
Stored size: 623 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
11 entries across 11 versions & 1 rubygems