aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport')
-rw-r--r--activesupport/test/time_zone_test.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/activesupport/test/time_zone_test.rb b/activesupport/test/time_zone_test.rb
index 620623b389..922449988b 100644
--- a/activesupport/test/time_zone_test.rb
+++ b/activesupport/test/time_zone_test.rb
@@ -285,6 +285,11 @@ class TimeZoneTest < Test::Unit::TestCase
assert_equal(-21_600, zone.utc_offset)
end
+ def test_unknown_zones_dont_store_mapping_keys
+ ActiveSupport::TimeZone["bogus"]
+ assert !ActiveSupport::TimeZone.zones_map.key?("bogus")
+ end
+
def test_new
assert_equal ActiveSupport::TimeZone["Central Time (US & Canada)"], ActiveSupport::TimeZone.new("Central Time (US & Canada)")
end