Skip to content
This repository
Browse code

TimeZone: fix base offset for Sri Jayawardenepura. Anchor tests for z…

…one offsets to more current date
  • Loading branch information...
commit 020a4113048be7166346cba6c59bbbca819de911 1 parent 02df503
Geoff Buesing authored November 13, 2008
2  activesupport/CHANGELOG
... ...
@@ -1,5 +1,7 @@
1 1
 *2.2.1 [RC2 or 2.2 final]*
2 2
 
  3
+* TimeZone: fix offset for Sri Jayawardenepura. Anchor tests for zone offsets to more current date [Geoff Buesing]
  4
+
3 5
 * TimeZone: Caracas GMT offset changed to -4:30 [#1361 state:resolved] [Phil Ross]
4 6
 
5 7
 * Added render :js for people who want to render inline JavaScript replies without using RJS [DHH]
4  activesupport/lib/active_support/values/time_zone.rb
@@ -326,9 +326,9 @@ def tzinfo
326 326
        [ 14_400, "Abu Dhabi", "Muscat", "Baku", "Tbilisi", "Yerevan" ],
327 327
        [ 16_200, "Kabul" ],
328 328
        [ 18_000, "Ekaterinburg", "Islamabad", "Karachi", "Tashkent" ],
329  
-       [ 19_800, "Chennai", "Kolkata", "Mumbai", "New Delhi" ],
  329
+       [ 19_800, "Chennai", "Kolkata", "Mumbai", "New Delhi", "Sri Jayawardenepura" ],
330 330
        [ 20_700, "Kathmandu" ],
331  
-       [ 21_600, "Astana", "Dhaka", "Sri Jayawardenepura", "Almaty",
  331
+       [ 21_600, "Astana", "Dhaka", "Almaty",
332 332
                  "Novosibirsk" ],
333 333
        [ 23_400, "Rangoon" ],
334 334
        [ 25_200, "Bangkok", "Hanoi", "Jakarta", "Krasnoyarsk" ],
2  activesupport/test/time_zone_test.rb
@@ -51,7 +51,7 @@ def test_from_duration_to_map
51 51
 
52 52
     define_method("test_utc_offset_for_#{name}") do
53 53
       silence_warnings do # silence warnings raised by tzinfo gem
54  
-        period = zone.tzinfo.period_for_utc(Time.utc(2006,1,1,0,0,0))
  54
+        period = zone.tzinfo.period_for_utc(Time.utc(2009,1,1,0,0,0))
55 55
         assert_equal period.utc_offset, zone.utc_offset
56 56
       end
57 57
     end

0 notes on commit 020a411

Please sign in to comment.
Something went wrong with that request. Please try again.