mirror of
https://github.com/tc39/test262.git
synced 2025-09-30 13:38:48 +02:00
This adds tests to every entry point where a Temporal.TimeZone is accepted, making sure that a time zone ID string is also accepted.
14 lines
439 B
JavaScript
14 lines
439 B
JavaScript
// Copyright (C) 2022 Igalia, S.L. All rights reserved.
|
|
// This code is governed by the BSD license found in the LICENSE file.
|
|
|
|
/*---
|
|
esid: sec-temporal.timezone.from
|
|
description: Time zone IDs are valid input for a time zone
|
|
features: [Temporal]
|
|
---*/
|
|
|
|
["UTC", "+01:30"].forEach((timeZone) => {
|
|
const result = Temporal.TimeZone.from(timeZone);
|
|
assert.sameValue(result.id, timeZone, `Time zone created from string "${timeZone}"`);
|
|
});
|