1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 21:57:43 +00:00

LibJS: Implement a nearly empty Intl.DateTimeFormat object

This adds plumbing for the Intl.DateTimeFormat object, constructor, and
prototype.

Note that unlike other Intl objects, the Intl.DateTimeFormat object has
a LibUnicode structure as a base. This is to prevent wild amounts of
code duplication between LibUnicode, Intl.DateTimeFormat, and other
not-yet-defined Intl structures, because there's 12 fields shared
between them.
This commit is contained in:
Timothy Flynn 2021-11-18 10:30:31 -05:00 committed by Linus Groh
parent 6dbdfb6ba1
commit 75b2a09a2f
12 changed files with 329 additions and 4 deletions

View file

@ -0,0 +1,3 @@
test("basic functionality", () => {
expect(Intl.DateTimeFormat.prototype[Symbol.toStringTag]).toBe("Intl.DateTimeFormat");
});

View file

@ -0,0 +1,5 @@
describe("normal behavior", () => {
test("length is 0", () => {
expect(Intl.DateTimeFormat).toHaveLength(0);
});
});