Sha256: 7563f2a09c89016fe6d39ec0415b35dbcc470e708981657d63a85f9eb342c5cc
Contents?: true
Size: 507 Bytes
Versions: 22
Compression:
Stored size: 507 Bytes
Contents
require File.expand_path(::File.dirname(__FILE__) + '/../lib/xml/smart') require File.expand_path(::File.dirname(__FILE__) + '/smartrunner.rb') class TestXpath < Minitest::Test def test_xpath doc = XML::Smart.open(::File.dirname(__FILE__) + "/EXAMPLE-NS.xml") doc.register_namespace 'des', 'http://example.org' doc.register_namespace 'ex', 'http://example1.org' assert(doc.find('//des:names').length == 1) nodesA = doc.root.find("des:names") assert(nodesA.length == 1) end end
Version data entries
22 entries across 22 versions & 1 rubygems