mirror of https://github.com/tc39/test262.git
28 lines
614 B
JavaScript
28 lines
614 B
JavaScript
// Copyright (C) 2022 André Bargull. All rights reserved.
|
|
// This code is governed by the BSD license found in the LICENSE file.
|
|
|
|
/*---
|
|
esid: sec-temporal.timezone
|
|
description: >
|
|
TimeZone constructor canonicalises its input.
|
|
features: [Temporal]
|
|
---*/
|
|
|
|
const testCases = {
|
|
"Etc/GMT": "UTC",
|
|
"Etc/GMT+0": "UTC",
|
|
"Etc/GMT-0": "UTC",
|
|
"Etc/GMT0": "UTC",
|
|
"Etc/Greenwich": "UTC",
|
|
"Etc/UCT": "UTC",
|
|
"Etc/UTC": "UTC",
|
|
"Etc/Universal": "UTC",
|
|
"Etc/Zulu": "UTC",
|
|
};
|
|
|
|
for (let [id, canonical] of Object.entries(testCases)) {
|
|
let tz = new Temporal.TimeZone(id);
|
|
|
|
assert.sameValue(tz.id, canonical);
|
|
}
|