tzinfo 0.3.58 → 0.3.59

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of tzinfo might be problematic. Click here for more details.

Files changed (31) hide show
  1. data/CHANGES +6 -0
  2. data/lib/tzinfo/definitions/Africa/Accra.rb +63 -47
  3. data/lib/tzinfo/definitions/Africa/Lagos.rb +8 -3
  4. data/lib/tzinfo/definitions/Africa/Nairobi.rb +7 -6
  5. data/lib/tzinfo/definitions/America/Belize.rb +50 -5
  6. data/lib/tzinfo/definitions/America/Grand_Turk.rb +1 -2
  7. data/lib/tzinfo/definitions/America/Nassau.rb +95 -88
  8. data/lib/tzinfo/definitions/Antarctica/Macquarie.rb +1 -1
  9. data/lib/tzinfo/definitions/Asia/Gaza.rb +15 -13
  10. data/lib/tzinfo/definitions/Asia/Hebron.rb +15 -13
  11. data/lib/tzinfo/definitions/Asia/Jerusalem.rb +29 -27
  12. data/lib/tzinfo/definitions/Atlantic/Bermuda.rb +186 -157
  13. data/lib/tzinfo/definitions/Australia/Adelaide.rb +5 -5
  14. data/lib/tzinfo/definitions/Australia/Brisbane.rb +5 -5
  15. data/lib/tzinfo/definitions/Australia/Broken_Hill.rb +5 -5
  16. data/lib/tzinfo/definitions/Australia/Currie.rb +1 -173
  17. data/lib/tzinfo/definitions/Australia/Darwin.rb +5 -5
  18. data/lib/tzinfo/definitions/Australia/Eucla.rb +4 -4
  19. data/lib/tzinfo/definitions/Australia/Hobart.rb +8 -4
  20. data/lib/tzinfo/definitions/Australia/Lindeman.rb +5 -5
  21. data/lib/tzinfo/definitions/Australia/Melbourne.rb +5 -5
  22. data/lib/tzinfo/definitions/Australia/Perth.rb +4 -4
  23. data/lib/tzinfo/definitions/Australia/Sydney.rb +5 -5
  24. data/lib/tzinfo/definitions/Europe/Volgograd.rb +1 -0
  25. data/lib/tzinfo/definitions/Indian/Mahe.rb +1 -1
  26. data/lib/tzinfo/definitions/Pacific/Efate.rb +3 -1
  27. data/lib/tzinfo/indexes/countries.rb +4 -5
  28. data/lib/tzinfo/indexes/timezones.rb +1 -1
  29. data/test/tc_timezone_melbourne.rb +21 -21
  30. data/tzinfo.gemspec +1 -1
  31. metadata +4 -4
@@ -53,48 +53,48 @@ class TCTimezoneMelbourne < Test::Unit::TestCase
53
53
  end
54
54
 
55
55
  def test_1942
56
- #Australia/Melbourne Sat Mar 28 14:59:59 1942 UTC = Sun Mar 29 01:59:59 1942 AEDT isdst=1 gmtoff=39600
57
- #Australia/Melbourne Sat Mar 28 15:00:00 1942 UTC = Sun Mar 29 01:00:00 1942 AEST isdst=0 gmtoff=36000
56
+ #Australia/Melbourne Sat Mar 28 15:59:59 1942 UTC = Sun Mar 29 02:59:59 1942 AEDT isdst=1 gmtoff=39600
57
+ #Australia/Melbourne Sat Mar 28 16:00:00 1942 UTC = Sun Mar 29 02:00:00 1942 AEST isdst=0 gmtoff=36000
58
58
  #Australia/Melbourne Sat Sep 26 15:59:59 1942 UTC = Sun Sep 27 01:59:59 1942 AEST isdst=0 gmtoff=36000
59
59
  #Australia/Melbourne Sat Sep 26 16:00:00 1942 UTC = Sun Sep 27 03:00:00 1942 AEDT isdst=1 gmtoff=39600
60
60
 
61
61
  tz = Timezone.get('Australia/Melbourne')
62
- assert_equal(DateTime.new(1942,3,29,1,59,59), tz.utc_to_local(DateTime.new(1942,3,28,14,59,59)))
63
- assert_equal(DateTime.new(1942,3,29,1,0,0), tz.utc_to_local(DateTime.new(1942,3,28,15,0,0)))
62
+ assert_equal(DateTime.new(1942,3,29,2,59,59), tz.utc_to_local(DateTime.new(1942,3,28,15,59,59)))
63
+ assert_equal(DateTime.new(1942,3,29,2,0,0), tz.utc_to_local(DateTime.new(1942,3,28,16,0,0)))
64
64
  assert_equal(DateTime.new(1942,9,27,1,59,59), tz.utc_to_local(DateTime.new(1942,9,26,15,59,59)))
65
65
  assert_equal(DateTime.new(1942,9,27,3,0,0), tz.utc_to_local(DateTime.new(1942,9,26,16,0,0)))
66
66
 
67
- assert_equal(DateTime.new(1942,3,28,14,59,59), tz.local_to_utc(DateTime.new(1942,3,29,1,59,59), true))
68
- assert_equal(DateTime.new(1942,3,28,15,59,59), tz.local_to_utc(DateTime.new(1942,3,29,1,59,59), false))
69
- assert_equal(DateTime.new(1942,3,28,14,0,0), tz.local_to_utc(DateTime.new(1942,3,29,1,0,0), true))
70
- assert_equal(DateTime.new(1942,3,28,15,0,0), tz.local_to_utc(DateTime.new(1942,3,29,1,0,0), false))
67
+ assert_equal(DateTime.new(1942,3,28,15,59,59), tz.local_to_utc(DateTime.new(1942,3,29,2,59,59), true))
68
+ assert_equal(DateTime.new(1942,3,28,16,59,59), tz.local_to_utc(DateTime.new(1942,3,29,2,59,59), false))
69
+ assert_equal(DateTime.new(1942,3,28,15,0,0), tz.local_to_utc(DateTime.new(1942,3,29,2,0,0), true))
70
+ assert_equal(DateTime.new(1942,3,28,16,0,0), tz.local_to_utc(DateTime.new(1942,3,29,2,0,0), false))
71
71
  assert_equal(DateTime.new(1942,9,26,15,59,59), tz.local_to_utc(DateTime.new(1942,9,27,1,59,59)))
72
72
  assert_equal(DateTime.new(1942,9,26,16,0,0), tz.local_to_utc(DateTime.new(1942,9,27,3,0,0)))
73
73
 
74
74
  assert_raises(PeriodNotFound) { tz.local_to_utc(DateTime.new(1942,9,27,2,0,0)) }
75
- assert_raises(AmbiguousTime) { tz.local_to_utc(DateTime.new(1942,3,29,1,0,0)) }
75
+ assert_raises(AmbiguousTime) { tz.local_to_utc(DateTime.new(1942,3,29,2,0,0)) }
76
76
 
77
- assert_equal(:AEDT, tz.period_for_utc(DateTime.new(1942,3,28,14,59,59)).zone_identifier)
78
- assert_equal(:AEST, tz.period_for_utc(DateTime.new(1942,3,28,15,0,0)).zone_identifier)
77
+ assert_equal(:AEDT, tz.period_for_utc(DateTime.new(1942,3,28,15,59,59)).zone_identifier)
78
+ assert_equal(:AEST, tz.period_for_utc(DateTime.new(1942,3,28,16,0,0)).zone_identifier)
79
79
  assert_equal(:AEST, tz.period_for_utc(DateTime.new(1942,9,26,15,59,59)).zone_identifier)
80
80
  assert_equal(:AEDT, tz.period_for_utc(DateTime.new(1942,9,26,16,0,0)).zone_identifier)
81
81
 
82
- assert_equal(:AEDT, tz.period_for_local(DateTime.new(1942,3,29,1,59,59), true).zone_identifier)
83
- assert_equal(:AEST, tz.period_for_local(DateTime.new(1942,3,29,1,59,59), false).zone_identifier)
84
- assert_equal(:AEDT, tz.period_for_local(DateTime.new(1942,3,29,1,0,0), true).zone_identifier)
85
- assert_equal(:AEST, tz.period_for_local(DateTime.new(1942,3,29,1,0,0), false).zone_identifier)
82
+ assert_equal(:AEDT, tz.period_for_local(DateTime.new(1942,3,29,2,59,59), true).zone_identifier)
83
+ assert_equal(:AEST, tz.period_for_local(DateTime.new(1942,3,29,2,59,59), false).zone_identifier)
84
+ assert_equal(:AEDT, tz.period_for_local(DateTime.new(1942,3,29,2,0,0), true).zone_identifier)
85
+ assert_equal(:AEST, tz.period_for_local(DateTime.new(1942,3,29,2,0,0), false).zone_identifier)
86
86
  assert_equal(:AEST, tz.period_for_local(DateTime.new(1942,9,27,1,59,59)).zone_identifier)
87
87
  assert_equal(:AEDT, tz.period_for_local(DateTime.new(1942,9,27,3,0,0)).zone_identifier)
88
88
 
89
- assert_equal(39600, tz.period_for_utc(DateTime.new(1942,3,28,14,59,59)).utc_total_offset)
90
- assert_equal(36000, tz.period_for_utc(DateTime.new(1942,3,28,15,0,0)).utc_total_offset)
89
+ assert_equal(39600, tz.period_for_utc(DateTime.new(1942,3,28,15,59,59)).utc_total_offset)
90
+ assert_equal(36000, tz.period_for_utc(DateTime.new(1942,3,28,16,0,0)).utc_total_offset)
91
91
  assert_equal(36000, tz.period_for_utc(DateTime.new(1942,9,26,15,59,59)).utc_total_offset)
92
92
  assert_equal(39600, tz.period_for_utc(DateTime.new(1942,9,26,16,0,0)).utc_total_offset)
93
93
 
94
- assert_equal(39600, tz.period_for_local(DateTime.new(1942,3,29,1,59,59), true).utc_total_offset)
95
- assert_equal(36000, tz.period_for_local(DateTime.new(1942,3,29,1,59,59), false).utc_total_offset)
96
- assert_equal(39600, tz.period_for_local(DateTime.new(1942,3,29,1,0,0), true).utc_total_offset)
97
- assert_equal(36000, tz.period_for_local(DateTime.new(1942,3,29,1,0,0), false).utc_total_offset)
94
+ assert_equal(39600, tz.period_for_local(DateTime.new(1942,3,29,2,59,59), true).utc_total_offset)
95
+ assert_equal(36000, tz.period_for_local(DateTime.new(1942,3,29,2,59,59), false).utc_total_offset)
96
+ assert_equal(39600, tz.period_for_local(DateTime.new(1942,3,29,2,0,0), true).utc_total_offset)
97
+ assert_equal(36000, tz.period_for_local(DateTime.new(1942,3,29,2,0,0), false).utc_total_offset)
98
98
  assert_equal(36000, tz.period_for_local(DateTime.new(1942,9,27,1,59,59)).utc_total_offset)
99
99
  assert_equal(39600, tz.period_for_local(DateTime.new(1942,9,27,3,0,0)).utc_total_offset)
100
100
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'tzinfo'
3
- s.version = '0.3.58'
3
+ s.version = '0.3.59'
4
4
  s.author = 'Philip Ross'
5
5
  s.email = 'phil.ross@gmail.com'
6
6
  s.homepage = 'http://tzinfo.github.io'
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tzinfo
3
3
  version: !ruby/object:Gem::Version
4
- hash: 103
4
+ hash: 101
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 58
10
- version: 0.3.58
9
+ - 59
10
+ version: 0.3.59
11
11
  platform: ruby
12
12
  authors:
13
13
  - Philip Ross
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2020-11-07 16:00:00 -08:00
18
+ date: 2020-12-23 16:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies: []
21
21