-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding support to validate an architecture without relying on a pattern #793
Adding support to validate an architecture without relying on a pattern #793
Conversation
} | ||
} catch (error) { | ||
logger.error('An error occured:', error); | ||
process.exit(1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if at some point it would make sense to not exit the process here, but instead in the CLI component instead which calls this code. I'm thinking from a reuse perspective, there could potentially be an app which doesn't want to exit when an error occurs, but instead just displays it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes I agree, this is something that we will probably need to do!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. This is going to be important for the CLI server, I would imagine. We want to just return the validation output back to the calling module
* @param failOnWarnings Whether or not to treat a warning as a failure in the validation process. | ||
* @param jsonSchemaLocation the location of the patterns JSON Schema to validate. | ||
* @param metaSchemaPath the path of the meta schemas to use for ajv. | ||
* @param debug the flag to enable debug logging. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small thing - might be good to have a dash after the param name, I was ever so briefly confused because I thought this was telling me to 'debug the flag' 😆
…ove readibility of docs
In this PR I added the support to validate an architecture without the need of a pattern. The architecture validation for now is based on the spectral rules that already exist in the project.