Hi!
I can’t figure out what is the format of the error messages for this task.
In the tests source I see that it is a map:
expected: #(error: “span must be greater than zero”)
Unfortunately my solutions for the test cases that should report errors fail. Has anyone any idea what’s going on?
Thanks!
IsaacG
October 5, 2023, 3:20pm
2
Can you paste the exact error message you get?
(Please use text and a codeblock; please do not use an image for text.)
I got the following:
FAILED. Expected: [type: user id: 'message arg1: "span must be smaller than string length"], but got #(
error: "span must be smaller than string length"
)
IsaacG
October 5, 2023, 8:09pm
4
What about your code? Are you returning an error object ?
OK,
I just relised that I should throw the error and not just return an error object :)
cause-error 'user 'message ["span must be greater than zero"]
Thanks for your time!
2 Likes