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

ruby-changes:33488

From: nobu <ko1@a...>
Date: Fri, 11 Apr 2014 15:53:36 +0900 (JST)
Subject: [ruby-changes:33488] nobu:r45567 (trunk): test_array.rb: skip if timed out

nobu	2014-04-11 15:53:28 +0900 (Fri, 11 Apr 2014)

  New Revision: 45567

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=45567

  Log:
    test_array.rb: skip if timed out
    
    * test/ruby/test_array.rb (test_shared_marking): skip if timed out,
      this test can just take a lot of time.

  Modified files:
    trunk/test/ruby/test_array.rb
Index: test/ruby/test_array.rb
===================================================================
--- test/ruby/test_array.rb	(revision 45566)
+++ test/ruby/test_array.rb	(revision 45567)
@@ -2452,10 +2452,11 @@ class TestArray < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/ruby/test_array.rb#L2452
         "...(snip #{$&.count("\n")} lines)...\n"
       end
     end
-    assert_normal_exit(<<-EOS, '[Bug #9718]', stdout_filter: reduce)
+    begin
+      assert_normal_exit(<<-EOS, '[Bug #9718]', timeout: 5, stdout_filter: reduce)
       queue = []
-      10.times do
-        100_000.times do
+      50.times do
+        10_000.times do
           queue << lambda{}
         end
         GC.start(full_mark: false, immediate_sweep: true)
@@ -2463,5 +2464,8 @@ class TestArray < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/ruby/test_array.rb#L2464
         queue.shift.call
       end
     EOS
+    rescue Timeout::Error => e
+      skip e.message
+    end
   end
 end

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

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