Enforce minLength on strings
What does this MR do?
Requiring a field in the JSON schemas is not enough to have a valid report. Indeed, go has zero values for strings, and they're empty strings when the omitempty
tag isn't set. This means some reports generated with the help of the Common library are considered valid from the JSON schema perspective (the field is present) but the parser will reject them because empty strings are not allowed.
Setting "minLength": 1
is a good sensible default for all strings, when patterns can't be enforced.
Availability and Testing
-
Review and add/update tests for this feature/bug
Approvals
-
groupcomposition analysis @fcatteau -
groupstatic analysis @theoretick -
groupdynamic analysis @cam_swords -
~"group::fuzz testing" (API fuzzing) @mikeeddington -
~"group::fuzz testing" (coverage fuzzing) @ypats
Edited by Fabien Catteau