From e9651deea4145f62224af56af027bfbb3e45e4cd Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Sat, 27 Jul 2019 12:49:45 +0900 Subject: Use assert_match / assert_no_match for asserting match --- activesupport/test/time_zone_test.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'activesupport') diff --git a/activesupport/test/time_zone_test.rb b/activesupport/test/time_zone_test.rb index f948c363df..0c3a10995c 100644 --- a/activesupport/test/time_zone_test.rb +++ b/activesupport/test/time_zone_test.rb @@ -712,9 +712,9 @@ class TimeZoneTest < ActiveSupport::TestCase def test_zone_match zone = ActiveSupport::TimeZone["Eastern Time (US & Canada)"] - assert zone =~ /Eastern/ - assert zone =~ /New_York/ - assert zone !~ /Nonexistent_Place/ + assert_match zone, /Eastern/ + assert_match zone, /New_York/ + assert_no_match zone, /Nonexistent_Place/ end def test_to_s -- cgit v1.2.3