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

ruby-changes:43684

From: nobu <ko1@a...>
Date: Tue, 26 Jul 2016 22:02:39 +0900 (JST)
Subject: [ruby-changes:43684] nobu:r55757 (trunk): test: use assert_include

nobu	2016-07-26 22:02:33 +0900 (Tue, 26 Jul 2016)

  New Revision: 55757

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

  Log:
    test: use assert_include

  Modified files:
    trunk/test/cgi/test_cgi_header.rb
    trunk/test/openssl/test_pair.rb
    trunk/test/ruby/test_time_tz.rb
Index: test/ruby/test_time_tz.rb
===================================================================
--- test/ruby/test_time_tz.rb	(revision 55756)
+++ test/ruby/test_time_tz.rb	(revision 55757)
@@ -390,7 +390,7 @@ End https://github.com/ruby/ruby/blob/trunk/test/ruby/test_time_tz.rb#L390
           ]
         }
       }
-      assert_includes(results, [true, true, true, true, true])
+      assert_include(results, [true, true, true, true, true])
     }
   end
 
Index: test/openssl/test_pair.rb
===================================================================
--- test/openssl/test_pair.rb	(revision 55756)
+++ test/openssl/test_pair.rb	(revision 55757)
@@ -497,13 +497,13 @@ module OpenSSL::TestPairM https://github.com/ruby/ruby/blob/trunk/test/openssl/test_pair.rb#L497
 
     until th.join(0.01)
       accepted = s2.accept_nonblock(exception: false)
-      assert_includes([s2, :wait_readable, :wait_writable ], accepted)
+      assert_include([s2, :wait_readable, :wait_writable ], accepted)
     end
 
     rets = th.value
     assert_instance_of Array, rets
     rets.each do |rv|
-      assert_includes([s1, :wait_readable, :wait_writable ], rv)
+      assert_include([s1, :wait_readable, :wait_writable ], rv)
     end
   ensure
     th.join if th
Index: test/cgi/test_cgi_header.rb
===================================================================
--- test/cgi/test_cgi_header.rb	(revision 55756)
+++ test/cgi/test_cgi_header.rb	(revision 55757)
@@ -147,7 +147,7 @@ class CGIHeaderTest < Test::Unit::TestCa https://github.com/ruby/ruby/blob/trunk/test/cgi/test_cgi_header.rb#L147
     date = /^Date: ([A-Z][a-z]{2}, \d{2} [A-Z][a-z]{2} \d{4} \d\d:\d\d:\d\d GMT)\r\n/
     [actual1, actual2, actual3].each do |actual|
       assert_match(date, actual)
-      assert_includes(time_start..time_end, date =~ actual && Time.parse($1).to_i)
+      assert_include(time_start..time_end, date =~ actual && Time.parse($1).to_i)
       actual.sub!(date, "Date: DATE_IS_REMOVED\r\n")
     end
     ## assertion

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

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