summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibJS/Tests/builtins
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2021-11-19 20:43:52 +0000
committerLinus Groh <mail@linusgroh.de>2021-11-20 23:10:09 +0000
commit98b876ad3f3d59dd83c91f8db0ea052ecde1d908 (patch)
tree6e664c891bf6c12d1fd276a2b1494f79e185df7a /Userland/Libraries/LibJS/Tests/builtins
parent3b1de431cc35c8886dd498ade0c9a90b268a95a1 (diff)
downloadserenity-98b876ad3f3d59dd83c91f8db0ea052ecde1d908.zip
LibJS: Implement parsing of TemporalZonedDateTimeString
Diffstat (limited to 'Userland/Libraries/LibJS/Tests/builtins')
-rw-r--r--Userland/Libraries/LibJS/Tests/builtins/Temporal/ZonedDateTime/ZonedDateTime.from.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/Userland/Libraries/LibJS/Tests/builtins/Temporal/ZonedDateTime/ZonedDateTime.from.js b/Userland/Libraries/LibJS/Tests/builtins/Temporal/ZonedDateTime/ZonedDateTime.from.js
index 7e9f9f9538..b662e9ce9b 100644
--- a/Userland/Libraries/LibJS/Tests/builtins/Temporal/ZonedDateTime/ZonedDateTime.from.js
+++ b/Userland/Libraries/LibJS/Tests/builtins/Temporal/ZonedDateTime/ZonedDateTime.from.js
@@ -148,4 +148,10 @@ describe("errors", () => {
});
}).toThrowWithMessage(TypeError, "Required property day is missing or undefined");
});
+
+ test("invalid zoned date time string", () => {
+ expect(() => {
+ Temporal.ZonedDateTime.from("foo");
+ }).toThrowWithMessage(RangeError, "Invalid zoned date time string 'foo'");
+ });
});