Sha256: 9d16b4a651e18dcb6676d15342540f07647d9f410df0040b3b12f4f28f829963

Contents?: true

Size: 682 Bytes

Versions: 4

Compression:

Stored size: 682 Bytes

Contents

# $Id: tc_xml_node2.rb 67 2006-04-17 13:30:22Z roscopeco $
require "libxml_test"
require 'test/unit'

class TC_XML_Node2 < Test::Unit::TestCase
  def setup()
    xp = XML::Parser.new()
    str = '<ruby_array uga="booga" foo="bar"><fixnum>one</fixnum><fixnum>two</fixnum></ruby_array>'
    assert_equal(str, xp.string = str)
    doc = xp.parse
    assert_instance_of(XML::Document, doc)
    assert_instance_of(XML::Node, doc.root)
    @root = doc.root
    assert_instance_of(XML::Node, @root)
  end

  def teardown()
    @root = nil
  end

  def test_xml_node_doc_get()
    GC.start
    assert_instance_of(XML::Node, @root)
    assert_instance_of(XML::Document, @root.doc)
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
libxml-ruby-0.5.0 tests/tc_xml_node2.rb
libxml-ruby-0.5.0.1 tests/tc_xml_node2.rb
libxml-ruby-0.5.1.0 tests/tc_xml_node2.rb
libxml-ruby-0.5.2.0 tests/tc_xml_node2.rb