diff options
Diffstat (limited to 'test/rexml')
-rw-r--r-- | test/rexml/xpath/test_text.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/rexml/xpath/test_text.rb b/test/rexml/xpath/test_text.rb index cea3b05731..7222388e1b 100644 --- a/test/rexml/xpath/test_text.rb +++ b/test/rexml/xpath/test_text.rb @@ -69,7 +69,9 @@ module REXMLTests assert_equal(1, nodes.size, "<b> has one element ancestor") nodes = @doc.get_elements('//b/ancestor::node()') assert_equal(2, nodes.size, "<b> has two node ancestors") - assert_kind_of REXML::Document, nodes[1] + nodes.sort_by!(&:name) + assert_kind_of REXML::Document, nodes[0] + assert_kind_of REXML::Element, nodes[1] end end end |