Skip to content
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

Update negative unit tests (the ones that check invalid schemas fail) to check the right amount of failure is happening #118

Open
joellabes opened this issue Feb 6, 2024 · 0 comments

Comments

@joellabes
Copy link
Collaborator

Follow on from the thread at #117 (comment)

Basically, our current invalid directory of unit tests is insufficiently smart - it will fail if a single schema item is invalid, so if we accidentally add something that is valid while believing it to be invalid, we won't be warned.

As far as I can tell, the best thing we can do to properly validate is to compare the outputs of the --all-errors flag in ajv-cli against a source-controlled list of expected errors which we'll need to manually update as we add new failing tests.

Open to alternative approaches

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant