summaryrefslogtreecommitdiff
path: root/test/ruby
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-03-25 02:50:17 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-03-25 02:50:17 +0000
commitd81591607172afe8c92e6de72f7fa515aaa3d0bf (patch)
tree599fba3c99c04f927663f70b43ea0e6956818834 /test/ruby
parent5f6bb0dc64832f36c32cc4c02e0c8a08cc68317c (diff)
* test/ruby/test_process.rb (TestProcess#test_no_curdir): skip silently on
Windows, because this tests a platform specific feature and it'll never be supported on ruby on Windows. * test/ruby/test_dir_m17n.rb (TestDir_M17N#test_filename_extutf8_invalid, TestDir_M17N#test_filename_as_bytes_extutf8): ditto. * test/open-uri/test_open-uri.rb (TestOpenURI#test_find_proxy_case_sensitive_env): ditto. * test/dl/test_handle.rb (DL::TestHandle#test_NEXT, DL::TestHandle#test_DEFAULT): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_dir_m17n.rb29
-rw-r--r--test/ruby/test_process.rb5
2 files changed, 16 insertions, 18 deletions
diff --git a/test/ruby/test_dir_m17n.rb b/test/ruby/test_dir_m17n.rb
index 81accb7f93..6701e0b1a5 100644
--- a/test/ruby/test_dir_m17n.rb
+++ b/test/ruby/test_dir_m17n.rb
@@ -26,7 +26,6 @@ class TestDir_M17N < Test::Unit::TestCase
end
def test_filename_extutf8_invalid
- skip "ruby on windows doesn't support invalid utf-8 path" if /mswin|mingw/ =~ RUBY_PLATFORM
with_tmpdir {|d|
assert_ruby_status(%w[-EASCII-8BIT], <<-'EOS', nil, :chdir=>d)
filename = "\xff".force_encoding("ASCII-8BIT") # invalid byte sequence as UTF-8
@@ -43,7 +42,7 @@ class TestDir_M17N < Test::Unit::TestCase
exit ents.include?(filename) || ((RUBY_PLATFORM =~ /darwin/) != nil && ents.include?("%FF"))
EOS
}
- end
+ end unless /mswin|mingw/ =~ RUBY_PLATFORM
def test_filename_as_bytes_extutf8
with_tmpdir {|d|
@@ -67,18 +66,20 @@ class TestDir_M17N < Test::Unit::TestCase
exit false
end
EOS
- skip "no meaning test on windows" if /mswin|mingw/ =~ RUBY_PLATFORM
- assert_ruby_status(%w[-EUTF-8], <<-'EOS', nil, :chdir=>d)
- filename1 = "\xc2\xa1".force_encoding("utf-8")
- filename2 = "\xc2\xa1".force_encoding("euc-jp")
- filename3 = filename1.encode("euc-jp")
- filename4 = filename2.encode("utf-8")
- s1 = File.stat(filename1) rescue nil
- s2 = File.stat(filename2) rescue nil
- s3 = File.stat(filename3) rescue nil
- s4 = File.stat(filename4) rescue nil
- exit((s1 && s2 && !s3 && !s4) ? true : false)
- EOS
+ # no meaning test on windows
+ unless /mswin|mingw/ =~ RUBY_PLATFORM
+ assert_ruby_status(%w[-EUTF-8], <<-'EOS', nil, :chdir=>d)
+ filename1 = "\xc2\xa1".force_encoding("utf-8")
+ filename2 = "\xc2\xa1".force_encoding("euc-jp")
+ filename3 = filename1.encode("euc-jp")
+ filename4 = filename2.encode("utf-8")
+ s1 = File.stat(filename1) rescue nil
+ s2 = File.stat(filename2) rescue nil
+ s3 = File.stat(filename3) rescue nil
+ s4 = File.stat(filename4) rescue nil
+ exit((s1 && s2 && !s3 && !s4) ? true : false)
+ EOS
+ end
}
end
diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb
index 39c8b18966..de1dcd0bd6 100644
--- a/test/ruby/test_process.rb
+++ b/test/ruby/test_process.rb
@@ -1209,9 +1209,6 @@ class TestProcess < Test::Unit::TestCase
end
def test_no_curdir
- if /mswin|bccwin|mingw/ =~ RUBY_PLATFORM
- skip "removing current directory is not supported"
- end
with_tmpchdir {|d|
Dir.mkdir("vd")
status = nil
@@ -1224,7 +1221,7 @@ class TestProcess < Test::Unit::TestCase
}
assert(status.success?, "[ruby-dev:38105]")
}
- end
+ end unless /mswin|bccwin|mingw/ =~ RUBY_PLATFORM
def test_fallback_to_sh
feature = '[ruby-core:32745]'