Closed aha79 closed 1 year ago
Such a schema isn't valid under the 2020 dialect's metaschema (specifically https://json-schema.org/draft/2020-12/meta/validation) which contains a minItems: 1
.
(And the same is true for earlier versions IIRC offhand).
Okay, but then meta/validation and the spec are out-of-sync. Perhaps the spec should say "non-empty array" or similar. But presently it doesnt. (But that is not a problem of the test-suite)
Yep I'd bring that up in the spec repo!
In types.json there are many tests, but none for "type" being an empty array. According to the spec this seems allowed
So
"type": []
should be the same as thefalse
schema.