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

ruby-changes:35428

From: ko1 <ko1@a...>
Date: Wed, 10 Sep 2014 16:24:44 +0900 (JST)
Subject: [ruby-changes:35428] ko1:r47510 (trunk): * test/ruby/test_gc.rb: fix condition.

ko1	2014-09-10 16:24:24 +0900 (Wed, 10 Sep 2014)

  New Revision: 47510

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

  Log:
    * test/ruby/test_gc.rb: fix condition.

  Modified files:
    trunk/ChangeLog
    trunk/test/ruby/test_gc.rb
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 47509)
+++ ChangeLog	(revision 47510)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Sep 10 16:22:26 2014  Koichi Sasada  <ko1@a...>
+
+	* test/ruby/test_gc.rb: fix condition.
+
 Wed Sep 10 15:29:46 2014  Eric Wong  <e@8...>
 
 	* vm_core.h (rb_call_info_t): ci->flag becomes 32-bit unsigned int
Index: test/ruby/test_gc.rb
===================================================================
--- test/ruby/test_gc.rb	(revision 47509)
+++ test/ruby/test_gc.rb	(revision 47510)
@@ -114,13 +114,13 @@ class TestGc < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/ruby/test_gc.rb#L114
   def test_stat_constraints
     stat = GC.stat
     assert_equal stat[:total_allocated_pages], stat[:heap_allocated_pages] + stat[:total_freed_pages]
-    assert_operator stat[:heap_sorted_length], :>=, stat[:heap_allocated_pages] + stat[:heap_allocatable_pages]
+    assert_operator stat[:heap_sorted_length], :>=, stat[:heap_eden_pages] + stat[:heap_allocatable_pages], "stat is: " + stat.inspect
     assert_equal stat[:heap_available_slots], stat[:heap_live_slots] + stat[:heap_free_slots] + stat[:heap_final_slots]
     assert_equal stat[:heap_live_slots], stat[:total_allocated_objects] - stat[:total_freed_objects] - stat[:heap_final_slots]
+    assert_equal stat[:heap_allocated_pages], stat[:heap_eden_pages] + stat[:heap_tomb_pages]
 
     if use_rgengc?
       assert_equal stat[:count], stat[:major_gc_count] + stat[:minor_gc_count]
-      assert_equal stat[:heap_allocated_pages], stat[:heap_eden_pages] + stat[:heap_tomb_pages]
     end
   end
 

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

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