From e3c86a37a8aaef928cfccdb5cea0f9e428f455ff Mon Sep 17 00:00:00 2001 From: mame Date: Mon, 23 Feb 2009 16:24:46 +0000 Subject: * bootstraptest/test_thread.rb: fix for environment where fork is not available. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@22578 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- bootstraptest/test_thread.rb | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'bootstraptest') diff --git a/bootstraptest/test_thread.rb b/bootstraptest/test_thread.rb index e586ee274..02cd2029a 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" -- cgit