The first step would be to run
npm install so we have all the required modules installed.
This runs the tests under tests directory.
azure-openapi-linterdirectory named same as the name of the rule. Add the
appliesTo_JsonQueryproperties to the rule.
appliesTo_JsonQueryis the node(s) to which the rule needs to be applied. This is evaluated using JsonPaths. Please refer here for a brief tutorial about JsonPaths.
runmethod under the rule that actually does the validation. Add a reference to this script file under
src\azure-openapi-linter\tests\resourcesand a script under
src\azure-openapi-linter\testsdepending on the type of the validation rule.