mirror of
https://github.com/github/rails.git
synced 2026-01-28 07:48:00 -05:00
TimeZone#to_s shows offset as GMT instead of UTC, because GMT will be more familiar to end users (see time zone selects used by Windows OS, google.com and yahoo.com.) Reverts [8370]
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
* TimeZone#to_s shows offset as GMT instead of UTC, because GMT will be more familiar to end users (see time zone selects used by Windows OS, google.com and yahoo.com.) Reverts [8370] [Geoff Buesing]
|
||||
|
||||
* Hash.from_xml: datetime xml types overflow to Ruby DateTime class when out of range of Time. Adding tests for utc offsets [Geoff Buesing]
|
||||
|
||||
* TimeWithZone #+ and #- : ensure overflow to DateTime with Numeric arg [Geoff Buesing]
|
||||
|
||||
@@ -202,7 +202,7 @@ class TimeZone
|
||||
|
||||
# Returns a textual representation of this time zone.
|
||||
def to_s
|
||||
"(UTC#{formatted_offset}) #{name}"
|
||||
"(GMT#{formatted_offset}) #{name}"
|
||||
end
|
||||
|
||||
# Method for creating new ActiveSupport::TimeWithZone instance in time zone of +self+ from given values. Example:
|
||||
|
||||
@@ -252,7 +252,7 @@ class TimeZoneTest < Test::Unit::TestCase
|
||||
end
|
||||
|
||||
def test_to_s
|
||||
assert_equal "(UTC+03:00) Moscow", TimeZone['Moscow'].to_s
|
||||
assert_equal "(GMT+03:00) Moscow", TimeZone['Moscow'].to_s
|
||||
end
|
||||
|
||||
def test_all_sorted
|
||||
|
||||
Reference in New Issue
Block a user