Sha256: 86b58e9c5cc74d1261fba7b0c8db5a5bc99da9672572d9dfa97ca787a5e9b913
Contents?: true
Size: 531 Bytes
Versions: 4
Compression:
Stored size: 531 Bytes
Contents
#!/usr/bin/ruby -w -I. require "libxml_test" $FAILS = [] def test( doc, doc2, iter ) doc.root = XML::Node.new("ccc") iter.times { |i| doc.root << doc2.root doc.root << doc2.root.copy(true) } return doc end def test2(iter) doc = XML::Document.new('1.0') doc2 = XML::Document.new('1.0') doc2.root = XML::Node.new("aaa") ret = test( doc, doc2, iter ) $FAILS << iter unless ret.find('*/aaa').length == iter end 1000.times do |i| puts i.to_s test2(i) end puts "#{$FAILS.length} failures" p $FAILS
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
libxml-ruby-0.5.0.1 | tests/copy_bug2.rb |
libxml-ruby-0.5.0 | tests/copy_bug2.rb |
libxml-ruby-0.3.8.2 | tests/copy_bug2.rb |
libxml-ruby-0.3.8.4 | tests/copy_bug2.rb |