From d7f06a665c8e5b4ec83b6baa4a7532fc7ad7f24a Mon Sep 17 00:00:00 2001 From: tenderlove Date: Tue, 14 May 2013 17:07:51 +0000 Subject: * test/psych/helper.rb: envutil is not available outside Ruby, so port the functions from envutil to the test helper. * test/psych/test_deprecated.rb: ditto * test/psych/test_encoding.rb: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/psych/test_encoding.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test/psych/test_encoding.rb') diff --git a/test/psych/test_encoding.rb b/test/psych/test_encoding.rb index 4f26fa3c9c..e370606c77 100644 --- a/test/psych/test_encoding.rb +++ b/test/psych/test_encoding.rb @@ -110,8 +110,8 @@ module Psych end def test_to_yaml_is_valid - EnvUtil.with_default_external(Encoding::US_ASCII) do - EnvUtil.with_default_internal(nil) do + with_default_external(Encoding::US_ASCII) do + with_default_internal(nil) do s = "こんにちは!" # If no encoding is specified, use UTF-8 assert_equal Encoding::UTF_8, Psych.dump(s).encoding @@ -182,7 +182,7 @@ module Psych end def test_default_internal - EnvUtil.with_default_internal(Encoding::EUC_JP) do + with_default_internal(Encoding::EUC_JP) do str = "壁に耳あり、障子に目あり" assert_equal @utf8, str.encoding -- cgit v1.2.3