mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
TimeZone offset tests: use current_period, to ensure TimeZone#utc_offset is up-to-date
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
*2.3.0/3.0*
|
||||
|
||||
* TimeZone offset tests: use current_period, to ensure TimeZone#utc_offset is up-to-date [Geoff Buesing]
|
||||
|
||||
* Update bundled TZInfo to 0.3.12 [Geoff Buesing]
|
||||
|
||||
* Added lambda merging to OptionMerger (especially useful with named_scope and with_options) #726 [Paweł Kondzior]
|
||||
|
||||
@@ -51,7 +51,7 @@ class TimeZoneTest < Test::Unit::TestCase
|
||||
|
||||
define_method("test_utc_offset_for_#{name}") do
|
||||
silence_warnings do # silence warnings raised by tzinfo gem
|
||||
period = zone.tzinfo.period_for_utc(Time.utc(2009,1,1,0,0,0))
|
||||
period = zone.tzinfo.current_period
|
||||
assert_equal period.utc_offset, zone.utc_offset
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user