Skip to content

Commit 57b05a4

Browse files
liurxliuRen Xie Liu
andauthored
Add microsoft timezone map (#23)
Co-authored-by: Ren Xie Liu <[email protected]>
1 parent 5e572e2 commit 57b05a4

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

lib/timezonedata/extrazones.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,4 +193,5 @@
193193
'UTC-11' => 'Pacific/Niue',
194194
'UTC+12' => 'Pacific/Auckland',
195195
'US Eastern Standard Time' => 'America/New_York',
196+
'tzone://Microsoft/Utc' => 'UTC',
196197
];

tests/VObject/TimeZoneUtilTest.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -354,4 +354,11 @@ public function testPrefixedOffsetExchangeIdentifier()
354354
$ex = new \DateTimeZone('America/New_York');
355355
$this->assertEquals($ex->getName(), $tz->getName());
356356
}
357+
358+
public function testMicrosoftMap()
359+
{
360+
$tz = TimeZoneUtil::getTimeZone('tzone://Microsoft/Utc', null, true);
361+
$ex = new \DateTimeZone('UTC');
362+
$this->assertEquals($ex->getName(), $tz->getName());
363+
}
357364
}

0 commit comments

Comments
 (0)