mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 05:37:34 +00:00
LibJS/Tests: Add test for Temporal.Instant.prototype.valueOf()
This commit is contained in:
parent
173630c5ef
commit
9d7e391f94
1 changed files with 7 additions and 0 deletions
|
@ -0,0 +1,7 @@
|
||||||
|
test("errors", () => {
|
||||||
|
test("throws TypeError", () => {
|
||||||
|
expect(() => {
|
||||||
|
new Temporal.Instant(0n).valueOf();
|
||||||
|
}).toThrowWithMessage(TypeError, "Cannot convert Temporal.Instant to a primitive value");
|
||||||
|
});
|
||||||
|
});
|
Loading…
Add table
Add a link
Reference in a new issue