Open
Description
Right now that is an array or a boolean:
"expErrors": {
"description": "The runtime errors expected to be emitted when formatting the message. If expErrors is either absent or empty, the message must be formatted without errors.",
"type": [
"array",
"boolean"
],
...
Why:
- Something that can be one of two different types makes it harder to consume the json from statically typed languages
- It is not useful in any way.
The description already says "If expErrors is either absent or empty, the message must be formatted without errors". That covers the possibleexpErrors = false
.
So we already have 2 ways to say "nothing fails", we don't need 3 ways.
And if we expect an error, then we should say what that error is, not just say "yes, we expect errors" (expErrors = true
).
The only use of expErrors
as boolean right now is in test/tests/functions/currency.json
, and all instances are "expErrors": false
.
Which is not needed (as per description missing expErrors
means no errors).
And that is what we do in all other tests, we don't specify expErrors
when none are expected.
Activity