# $Id: tc_xml_node7.rb,v 1.2 2006/11/20 01:22:08 roscopeco Exp $ require "libxml_test" require 'test/unit' class TC_XML_Node7 < Test::Unit::TestCase def setup() xp = XML::Parser.string('onetwo') doc = xp.parse @root = doc.root assert_equal 'bar', @root['foo'] end def teardown() @root = nil end def test_xml_node_properties_traversal_bug() prop = @root.properties assert_instance_of XML::Attr, prop assert_equal 'uga', prop.name assert_equal 'booga', prop.value prop = prop.next assert_instance_of XML::Attr, prop assert_equal 'foo', prop.name assert_equal 'bar', prop.value end end