From 8f90ac7827787a84b38055e1011ef9aedd89fe91 Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Mon, 29 Jul 2019 14:05:18 +0900 Subject: Add AS::TimeZone#match? --- actionview/test/template/form_options_helper_test.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'actionview/test') diff --git a/actionview/test/template/form_options_helper_test.rb b/actionview/test/template/form_options_helper_test.rb index d7a7b95ab3..273646b077 100644 --- a/actionview/test/template/form_options_helper_test.rb +++ b/actionview/test/template/form_options_helper_test.rb @@ -47,6 +47,7 @@ class FormOptionsHelperTest < ActionView::TestCase FakeZone = Struct.new(:name) do def to_s; name; end def =~(_re); end + def match?(_re); end end module ClassMethods @@ -1266,6 +1267,7 @@ class FormOptionsHelperTest < ActionView::TestCase @fake_timezones.each do |tz| def tz.=~(re); %(A D).include?(name) end + def tz.match?(re); %(A D).include?(name) end end html = time_zone_select("firm", "time_zone", /A|D/) -- cgit v1.2.3