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

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

This commit is contained in:
Linus Groh 2021-08-15 01:10:47 +01:00
parent c2ed3ad66b
commit 7fb05eb878
3 changed files with 23 additions and 0 deletions

View file

@ -0,0 +1,11 @@
describe("errors", () => {
test("throws TypeError", () => {
const plainMonthDay = new Temporal.PlainMonthDay(7, 6);
expect(() => {
plainMonthDay.valueOf();
}).toThrowWithMessage(
TypeError,
"Cannot convert Temporal.PlainMonthDay to a primitive value"
);
});
});