-
-
Notifications
You must be signed in to change notification settings - Fork 238
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
Implement InList and NotInList methods #250
Comments
Hi @gavv, I have created PR for this issue: #256 Could you check it? and let me know how it goes PS.
|
Thanks for pr! Will take a look shortly. Re: PS
|
Addressed in 40c6e50. Sure, thanks for your awesome repo as well 💯 |
Reopening after auto-close because we also need to update example. |
Created follow-up issue: #261 |
I've tagged v2.11.0, which includes InList. |
Great, thanks!! Please leave a comment there so that I can assign it to you. |
Some matcher structs (Number, DateTime) have
InRange
method that checks that the value belongs to given range[min; max]
.Another convenient thing would be
InList
method, that checks that the value equals to one of the given valuesa, b, c, ...
.For example:
We need to add
InList
and counterpartNotInList
methods to the following structs:The new methods can use assertions of type AssertBelongs and AssertNotBelongs. Please place these methods after
InRange
, or afterEqual*
if there is noInRange
for this struct.Each method should have documentation comment with code example and be covered by a unit test. It would be also nice to demonstrate usage of InRange and InList in
_examples/fruits_test.go
.The text was updated successfully, but these errors were encountered: