raml-org / raml-java-parser

(deprecated) A RAML parser based on SnakeYAML written in Java
Other
174 stars 121 forks source link

TypeDeclaration validation result is List<RamlValidationResult> with only one result #635

Open increatum opened 5 years ago

increatum commented 5 years ago

when validating JSON body of resource the result of validation is one error string with concatenation of all errors using new line and dash, for example:

[Error validating JSON. Error: - Invalid type String, expected Integer for clientId
- Invalid type String, expected Integer for ownershipPercentage
- Provided value 2017010100000000 is not compliant with the format date_only provided in rfc3339 for pacStartDate
- Invalid type String, expected Float for pacTotal
- Missing required field "dealerCode"]

each validation error should yield separate RamlValidationResult and should include error path

Aha! Link: https://mulesoft-roadmap.aha.io/features/APIRAML-35