Closed fmontei closed 7 years ago
@fmontei Do you want to merge this as a basis for future changes based on the slightly updated design?
@mark-burnett I might abandon this and add this to another PR if needed.
Moved to Gerrithub: https://review.gerrithub.io/#/c/373122/
This PR adds schemas for document pre-validation.
Validation is broken up into 2 stages: 1) Validate that each document contains the basic bulding blocks needed: "schema", "metadata" and "data" using a "base" schema. 2) Validate each specific document type (e.g. validation policy) using a more detailed schema.
Thus, a base schema was added for step 1) that validates that the basic properties are present and valid. In addition, more specific schemas were also added for step 2):
Unit tests were also added and updated to work with these above changes.