diff options
author | mame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-23 16:24:46 +0000 |
---|---|---|
committer | mame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-23 16:24:46 +0000 |
commit | c43236eaf78b7b74dfa7a41456d347deb2b5da1f (patch) | |
tree | 5d154f21e2cb389e70a70ed82017fe30ee5a0557 /bootstraptest | |
parent | c55dd9b7d8cf71f62709dab492f4221f090a6a79 (diff) | |
download | ruby-c43236eaf78b7b74dfa7a41456d347deb2b5da1f.tar.gz |
* bootstraptest/test_thread.rb: fix for environment where fork is not
available.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22578 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bootstraptest')
-rw-r--r-- | bootstraptest/test_thread.rb | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/bootstraptest/test_thread.rb b/bootstraptest/test_thread.rb index e586ee274e..02cd2029aa 100644 --- a/bootstraptest/test_thread.rb +++ b/bootstraptest/test_thread.rb @@ -219,9 +219,13 @@ assert_equal 'true', %{ assert_equal 'ok', %{ open("zzz.rb", "w") do |f| f.puts <<-END - Thread.new { fork { GC.start } }.join - pid, status = Process.wait2 - $result = status.success? ? :ok : :ng + begin + Thread.new { fork { GC.start } }.join + pid, status = Process.wait2 + $result = status.success? ? :ok : :ng + rescue NotImplementedError + :ok + end END end require "zzz.rb" |