LibJS: Implement Temporal.PlainTime.prototype.valueOf()

This commit is contained in:
Linus Groh 2021-07-28 18:42:34 +01:00
commit ad89a205bc
Notes: sideshowbarker 2024-07-18 07:58:11 +09:00
3 changed files with 21 additions and 0 deletions

View file

@ -0,0 +1,7 @@
test("errors", () => {
test("throws TypeError", () => {
expect(() => {
new Temporal.PlainTime(19, 54, 38).valueOf();
}).toThrowWithMessage(TypeError, "Cannot convert Temporal.PlainTime to a primitive value");
});
});