mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 23:37:36 +00:00
LibJS: Implement Temporal.PlainYearMonth.prototype.valueOf()
This commit is contained in:
parent
d9ed0f1f47
commit
5a260fcad1
3 changed files with 23 additions and 0 deletions
|
@ -0,0 +1,11 @@
|
|||
describe("errors", () => {
|
||||
test("throws TypeError", () => {
|
||||
const plainYearMonth = new Temporal.PlainYearMonth(2021, 7);
|
||||
expect(() => {
|
||||
plainYearMonth.valueOf();
|
||||
}).toThrowWithMessage(
|
||||
TypeError,
|
||||
"Cannot convert Temporal.PlainYearMonth to a primitive value"
|
||||
);
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue