[Groonga-commit] droonga/drntest at 967fc1f [master] Show summary at the last

Back to archive index

Yoji Shidara null+****@clear*****
Thu Sep 19 17:01:40 JST 2013


Yoji Shidara	2013-09-19 17:01:40 +0900 (Thu, 19 Sep 2013)

  New Revision: 967fc1f4fd4b9e2e43a35a8613ebfbfa19240199
  https://github.com/droonga/drntest/commit/967fc1f4fd4b9e2e43a35a8613ebfbfa19240199

  Message:
    Show summary at the last

  Modified files:
    lib/drntest/test-suites-result.rb
    lib/drntest/tester.rb

  Modified: lib/drntest/test-suites-result.rb (+8 -0)
===================================================================
--- lib/drntest/test-suites-result.rb    2013-09-19 16:58:06 +0900 (f05120d)
+++ lib/drntest/test-suites-result.rb    2013-09-19 17:01:40 +0900 (78b589b)
@@ -5,5 +5,13 @@ module Drntest
     def initialize
       @test_results = []
     end
+
+    def summary
+      status_counts = Hash.new(0)
+      test_results.each do |result|
+        status_counts[result.status] += 1
+      end
+      status_counts
+    end
   end
 end

  Modified: lib/drntest/tester.rb (+5 -0)
===================================================================
--- lib/drntest/tester.rb    2013-09-19 16:58:06 +0900 (d5568a1)
+++ lib/drntest/tester.rb    2013-09-19 17:01:40 +0900 (4d13e0e)
@@ -65,6 +65,11 @@ module Drntest
           result.status
         ]
       end
+
+      puts
+      puts "==== Summary ===="
+      p test_suites_result.summary
+
       0 # FIXME
     end
 
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index