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

ruby-changes:22691

From: sorah <ko1@a...>
Date: Wed, 22 Feb 2012 18:47:36 +0900 (JST)
Subject: [ruby-changes:22691] sorah:r34740 (trunk): * lib/test/unit.rb (setup_options): add option "--show-skip" to

sorah	2012-02-22 18:47:24 +0900 (Wed, 22 Feb 2012)

  New Revision: 34740

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

  Log:
    * lib/test/unit.rb (setup_options): add option "--show-skip" to
      cancel "--hide-skip" (-q)

  Modified files:
    trunk/ChangeLog
    trunk/lib/test/unit.rb
    trunk/test/testunit/test_hideskip.rb

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 34739)
+++ ChangeLog	(revision 34740)
@@ -1,3 +1,8 @@
+Wed Feb 22 18:34:02 2012  Shota Fukumori  <sorah@t...>
+
+	* lib/test/unit.rb (setup_options): add option "--show-skip" to
+	  cancel "--hide-skip" (-q)
+
 Wed Feb 22 17:36:22 2012  Nobuyoshi Nakada  <nobu@r...>
 
 	* io.c (rb_io_s_foreach): argument check before making Enumerator.
Index: lib/test/unit.rb
===================================================================
--- lib/test/unit.rb	(revision 34739)
+++ lib/test/unit.rb	(revision 34740)
@@ -112,6 +112,10 @@
         opts.on '-q', '--hide-skip', 'Hide skipped tests' do
           options[:hide_skip] = true
         end
+
+        opts.on '--show-skip', 'Show skipped tests' do
+          options[:hide_skip] = false
+        end
       end
 
       def non_options(files, options)
Index: test/testunit/test_hideskip.rb
===================================================================
--- test/testunit/test_hideskip.rb	(revision 34739)
+++ test/testunit/test_hideskip.rb	(revision 34740)
@@ -11,6 +11,13 @@
 
     test_out, o = IO.pipe
     spawn(*@options[:ruby], "#{File.dirname(__FILE__)}/test4test_hideskip.rb",
+          "--show-skip", out: o, err: o)
+    o.close
+    assert_match(/assertions\/s.\n\n  1\) Skipped/,test_out.read)
+    test_out.close
+
+    test_out, o = IO.pipe
+    spawn(*@options[:ruby], "#{File.dirname(__FILE__)}/test4test_hideskip.rb",
           "--hide-skip", out: o, err: o)
     o.close
     assert_match(/assertions\/s.\n\n1 tests, 0 assertions, 0 failures, 0 errors, 1 skips/,

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

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