mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 23:47:45 +00:00
LibJS: Implement the ECMA-402 definition of DefaultTimeZone
Simply defer to LibTimeZone to retrieve the system's current time zone. Also update some Temporal tests to explicitly set the time zone to UTC.
This commit is contained in:
parent
bdf02c21e1
commit
f6786881aa
6 changed files with 10 additions and 10 deletions
|
@ -15,7 +15,7 @@ describe("correct behavior", () => {
|
|||
return 86400000000000;
|
||||
},
|
||||
};
|
||||
const plainDate = Temporal.Now.plainDateISO();
|
||||
const plainDate = Temporal.Now.plainDateISO("UTC");
|
||||
const plainDateWithOffset = Temporal.Now.plainDateISO(timeZone);
|
||||
if (plainDate.dayOfYear === plainDate.daysInYear) {
|
||||
expect(plainDateWithOffset.year).toBe(plainDate.year + 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue