Added less than equal and greater than equal operations, and 13 new test cases for equality checking #804
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Justification
A common pattern in my codebase is to check for inequalities. But sometimes 13 must be included in the range. The typical solution is to do...
This can be a bit tedious to write and cumbersome for code readability.
Solution
This PR add methods that aggregates the condition into a single convenient function
The example above allows for a cleaner code, enhancing the readability experience.
This should also benefit other codebases.
Additional Changes
13new test cases has also been added to ensure that the changes don't break when new functionality is added or existing ones are modified.I've also noticed that the
notoperation doesn't have an existing test so I've added one for it for good measure.is-thirteen$ npm run testedit: Added sample of tests successfully running