1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

test: use assert_include

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55757 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2016-07-26 13:02:33 +00:00
parent 7b3473a13a
commit e7440de279
3 changed files with 4 additions and 4 deletions

View file

@ -147,7 +147,7 @@ class CGIHeaderTest < Test::Unit::TestCase
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