We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5f88802 commit 90d3332Copy full SHA for 90d3332
1 file changed
test/xpath/test_base.rb
@@ -100,6 +100,16 @@ def test_root
100
assert_equal "a", XPath::first( doc, "/" ).elements[1].name
101
end
102
103
+ def test_empty_doc
104
+ assert_equal [], XPath.match([], '*')
105
+ end
106
+
107
+ def test_nil_doc
108
+ assert_raise(NoMethodError) {
109
+ XPath.match(nil, '*')
110
+ }
111
112
113
def test_abbreviated_simple_child
114
assert_equal "a", XPath::first(@@doc, "a").name
115
0 commit comments