From 994f066f76857a781f8819b8da2c2aeceedbf87b Mon Sep 17 00:00:00 2001 From: kou Date: Sat, 30 Oct 2010 12:10:56 +0000 Subject: * lib/rexml/encoding.rb: use Ruby native encoding mechnism. [ruby-dev:42464] * lib/rexml/encodings/: remove. * lib/rexml/document.rb, lib/rexml/formatters/default.rb, lib/rexml/output.rb, lib/rexml/parseexception.rb, lib/rexml/parsers/baseparser.rb, lib/rexml/source.rb, lib/rexml/xmldecl.rb: use Ruby's native Encoding object. * test/rexml/, test/rss/: follow the above encoding chagnes. * NEWS: add REXML's incompatible change about encoding. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29646 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/rexml/test_contrib.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test/rexml/test_contrib.rb') diff --git a/test/rexml/test_contrib.rb b/test/rexml/test_contrib.rb index 785169bdd0..f448b0fe4a 100644 --- a/test/rexml/test_contrib.rb +++ b/test/rexml/test_contrib.rb @@ -241,7 +241,7 @@ DELIMITER end doc = REXML::Document.new(source_iso) - assert_equal('ISO-8859-1', doc.xml_decl.encoding) + assert_equal('ISO-8859-1', doc.xml_decl.encoding.to_s) assert_equal(koln_utf, doc.root.text) doc.write(out="") assert_equal(source_iso, out ) @@ -270,7 +270,7 @@ EOF expected_utf = expected_iso.unpack('C*').pack('U*') if expected_utf.respond_to? :encode expected_iso.force_encoding("iso-8859-1") - expected_utf.force_encoding(Encoding::UTF_8) + expected_utf.force_encoding(::Encoding::UTF_8) end assert_equal(expected_utf, tn.to_s.strip) f = REXML::Formatters::Default.new -- cgit v1.2.3