-
Notifications
You must be signed in to change notification settings - Fork 464
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split into two separate tests and move into test/intl402
- Loading branch information
1 parent
4af1bba
commit 119f650
Showing
2 changed files
with
20 additions
and
4 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
test/intl402/Temporal/ZonedDateTime/prototype/hoursInDay/same-date-starts-twice.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// Copyright (C) 2024 Igalia, S.L. All rights reserved. | ||
// This code is governed by the BSD license found in the LICENSE file. | ||
|
||
/*--- | ||
esid: sec-temporal.zoneddatetime.from | ||
description: Handles dates with offset transitions where midnight occurs twice. | ||
includes: [temporalHelpers.js] | ||
features: [Temporal] | ||
---*/ | ||
|
||
// Test date with offset transition where the same day starts twice | ||
// See https://github.com/tc39/proposal-temporal/issues/2938 for more details | ||
|
||
const zdt1 = Temporal.ZonedDateTime.from('2010-11-06T00:00:00-02:30[America/St_Johns]'); | ||
const zdt2 = Temporal.ZonedDateTime.from('2010-11-07T23:00:00-03:30[America/St_Johns]'); | ||
const zdt3 = Temporal.ZonedDateTime.from('2010-11-08T23:00:00-03:30[America/St_Johns]'); | ||
|
||
assert.sameValue(zdt1.hoursInDay, 24); | ||
assert.sameValue(zdt2.hoursInDay, 25); | ||
assert.sameValue(zdt3.hoursInDay, 24); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters