summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-12-04 16:39:55 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-12-04 16:39:55 +0000
commit0b10c320795e0784d9e4d269ece8f53f79ff3dd6 (patch)
tree0a365d818cfae0935595c1f868336fac0b4a421c
parent53e7e2d2a136c1aa4b859fc7e6590ef793c6bd11 (diff)
* test/ruby/test_process.rb: skip some tests on win32.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_process.rb20
1 files changed, 13 insertions, 7 deletions
diff --git a/test/ruby/test_process.rb b/test/ruby/test_process.rb
index ea902446559..97b48827b7a 100644
--- a/test/ruby/test_process.rb
+++ b/test/ruby/test_process.rb
@@ -127,6 +127,7 @@ class TestProcess < Test::Unit::TestCase
end
def test_execopts_pgroup
+ skip "system(:pgroup) is not supported" if /mswin|bccwin|mingw/ =~ RUBY_PLATFORM
assert_nothing_raised { system(*TRUECOMMAND, :pgroup=>false) }
io = IO.popen([RUBY, "-e", "print Process.getpgrp"])
@@ -495,6 +496,7 @@ class TestProcess < Test::Unit::TestCase
end
def test_fd_inheritance
+ skip "inheritance of fd>=3 is not supported" if /mswin|bccwin|mingw/ =~ RUBY_PLATFORM
with_pipe {|r, w|
system(RUBY, '-e', 'IO.new(ARGV[0].to_i).puts(:ba)', w.fileno.to_s)
w.close
@@ -598,14 +600,18 @@ class TestProcess < Test::Unit::TestCase
end
def test_execopts_redirect_self
- with_pipe {|r, w|
- w << "haha\n"
- w.close
- r.close_on_exec = true
- IO.popen([RUBY, "-e", "print IO.new(#{r.fileno}).read", r.fileno=>r.fileno, :close_others=>false]) {|io|
- assert_equal("haha\n", io.read)
+ begin
+ with_pipe {|r, w|
+ w << "haha\n"
+ w.close
+ r.close_on_exec = true
+ IO.popen([RUBY, "-e", "print IO.new(#{r.fileno}).read", r.fileno=>r.fileno, :close_others=>false]) {|io|
+ assert_equal("haha\n", io.read)
+ }
}
- }
+ rescue NotImplementedError
+ skip "IO#close_on_exec= is not supported"
+ end
end
def test_execopts_duplex_io