[前][次][番号順一覧][スレッド一覧]

ruby-changes:3687

From: ko1@a...
Date: Wed, 23 Jan 2008 11:23:33 +0900 (JST)
Subject: [ruby-changes:3687] usa - Ruby:r15176 (trunk): * bootstraptest/test_{knownbug,thread}.rb: support fork-less platform.

usa	2008-01-23 11:23:21 +0900 (Wed, 23 Jan 2008)

  New Revision: 15176

  Modified files:
    trunk/bootstraptest/test_knownbug.rb
    trunk/bootstraptest/test_thread.rb

  Log:
    * bootstraptest/test_{knownbug,thread}.rb: support fork-less platform.


  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/bootstraptest/test_thread.rb?r1=15176&r2=15175&diff_format=u
  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/bootstraptest/test_knownbug.rb?r1=15176&r2=15175&diff_format=u

Index: bootstraptest/test_knownbug.rb
===================================================================
--- bootstraptest/test_knownbug.rb	(revision 15175)
+++ bootstraptest/test_knownbug.rb	(revision 15176)
@@ -68,11 +68,15 @@
 
 assert_equal 'true', %{
   t = Thread.new { loop {} }
-  pid = fork {
+  begin
+    pid = fork {
       exit t.status != "run"
-  }
-  Process.wait pid
-  $?.success?
+    }
+    Process.wait pid
+    $?.success?
+  rescue NotImplementedError
+    true
+  end
 }
 
 assert_valid_syntax('1.times {|i|print (42),1;}', '[ruby-list:44479]')
Index: bootstraptest/test_thread.rb
===================================================================
--- bootstraptest/test_thread.rb	(revision 15175)
+++ bootstraptest/test_thread.rb	(revision 15176)
@@ -202,9 +202,13 @@
 }, '[ruby-dev:31371]'
 assert_equal 'true', %{
   t = Thread.new { loop {} }
-  pid = fork {
+  begin
+    pid = fork {
       exit t.status != "run"
-  }
-  Process.wait pid
-  $?.success?
+    }
+    Process.wait pid
+    $?.success?
+  rescue NotImplementedError
+    true
+  end
 }

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]