Project

General

Profile

Feature #12034 ยป 0002-follow-up-for-OS-X.patch

fix failures on OS X - nobu (Nobuyoshi Nakada), 02/09/2016 04:31 AM

View differences:

test/ruby/test_dir_m17n.rb
196 196
        opts = {:encoding => Encoding.default_external} if /mswin|mingw/ =~ RUBY_PLATFORM
197 197
        ents = Dir.entries(".", opts)
198 198
        if /darwin/ =~ RUBY_PLATFORM
199
          filename = filename.encode("utf-8").force_encoding("euc-jp")
199
          filename = filename.encode("utf-8").b
200 200
        end
201 201
        assert_include(ents, filename)
202 202
      EOS
......
241 241
        opts = {:encoding => Encoding.default_external} if /mswin|mingw/ =~ RUBY_PLATFORM
242 242
        ents = Dir.entries(".", opts)
243 243
        if /darwin/ =~ RUBY_PLATFORM
244
          filename = filename.encode("utf-8", "euc-jp").force_encoding("euc-jp")
244
          filename = filename.encode("utf-8").b
245 245
        end
246 246
        assert_include(ents, filename)
247 247
      EOS
......
250 250
        opts = {:encoding => Encoding.default_external} if /mswin|mingw/ =~ RUBY_PLATFORM
251 251
        ents = Dir.entries(".", opts)
252 252
        if /darwin/ =~ RUBY_PLATFORM
253
          filename = filename.force_encoding("euc-jp")
253
          filename = filename.b
254 254
        end
255 255
        assert_include(ents, filename)
256 256
      EOS
257
-