yassun7010 / serde_valid

JSON Schema based validation tool using serde.
MIT License
45 stars 10 forks source link

Fix invalid custom test case #82

Closed Esco441-91 closed 2 months ago

Esco441-91 commented 2 months ago

Summary

There is a logical fault in one of the custom test cases. It returned after one of the conditions was checked, not both. Fix it by not returning Ok on the first condition. It is done as a quick fix by removing the first case and inverting the tests, as I am not aware of the repository preferences.

As a bonus, add unhappy test cases to both of the custom tests to catch similar in the future.