diff options
author | duerst <duerst@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-19 07:55:25 +0000 |
---|---|---|
committer | duerst <duerst@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-06-19 07:55:25 +0000 |
commit | b67ead14521fb74bcf8ec28f8c78245dfb536b70 (patch) | |
tree | 67b912fec1f03fc66df3db88c72680226f191569 | |
parent | a42466584ca94a6eb8b56b5f3a4365ce9e3506c0 (diff) |
* test/ruby/test_dir_m17n.rb: Skip tests with non-UTF-8 encodings
on cygwin. Cygwin can use the Unicode PUA (private use area) to store
bytes from non-UTF-8 filenames (see
https://cygwin.com/cygwin-ug-net/using-specialnames.html#pathnames-specialchars),
but we are not supporting this. [Bug #12443]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55453 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | test/ruby/test_dir_m17n.rb | 5 |
2 files changed, 13 insertions, 0 deletions
@@ -1,3 +1,11 @@ +Sun Jun 19 16:55:16 2016 Martin Duerst <duerst@it.aoyama.ac.jp> + + * test/ruby/test_dir_m17n.rb: Skip tests with non-UTF-8 encodings + on cygwin. Cygwin can use the Unicode PUA (private use area) to store + bytes from non-UTF-8 filenames (see + https://cygwin.com/cygwin-ug-net/using-specialnames.html#pathnames-specialchars), + but we are not supporting this. [Bug #12443] + Sun Jun 19 15:01:18 2016 Martin Duerst <duerst@it.aoyama.ac.jp> * localeinit.c: Fix filesystem encoding for cygwin to UTF-8 (see diff --git a/test/ruby/test_dir_m17n.rb b/test/ruby/test_dir_m17n.rb index 4efc8ca34d..754c035ccb 100644 --- a/test/ruby/test_dir_m17n.rb +++ b/test/ruby/test_dir_m17n.rb @@ -21,6 +21,7 @@ class TestDir_M17N < Test::Unit::TestCase assert_include(ents, filename) EOS + return if /cygwin/ =~ RUBY_PLATFORM assert_separately(%w[-EASCII-8BIT], <<-EOS, :chdir=>dir) filename = #{code}.chr('UTF-8').force_encoding("ASCII-8BIT") opts = {:encoding => Encoding.default_external} if /mswin|mingw/ =~ RUBY_PLATFORM @@ -57,6 +58,7 @@ class TestDir_M17N < Test::Unit::TestCase end def test_filename_extutf8_invalid + return if /cygwin/ =~ RUBY_PLATFORM with_tmpdir {|d| assert_separately(%w[-EASCII-8BIT], <<-'EOS', :chdir=>d) filename = "\xff".force_encoding("ASCII-8BIT") # invalid byte sequence as UTF-8 @@ -172,6 +174,7 @@ class TestDir_M17N < Test::Unit::TestCase ## others def test_filename_bytes_euc_jp + return if /cygwin/ =~ RUBY_PLATFORM with_tmpdir {|d| assert_separately(%w[-EEUC-JP], <<-'EOS', :chdir=>d) filename = "\xA4\xA2".force_encoding("euc-jp") @@ -188,6 +191,7 @@ class TestDir_M17N < Test::Unit::TestCase end def test_filename_euc_jp + return if /cygwin/ =~ RUBY_PLATFORM with_tmpdir {|d| assert_separately(%w[-EEUC-JP], <<-'EOS', :chdir=>d) filename = "\xA4\xA2".force_encoding("euc-jp") @@ -233,6 +237,7 @@ class TestDir_M17N < Test::Unit::TestCase end def test_filename_ext_euc_jp_and_int_utf_8 + return if /cygwin/ =~ RUBY_PLATFORM with_tmpdir {|d| assert_separately(%w[-EEUC-JP], <<-'EOS', :chdir=>d) filename = "\xA4\xA2".force_encoding("euc-jp") |