-
Notifications
You must be signed in to change notification settings - Fork 105
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
forAll
doesn't support explicit generator being passed
#277
Comments
In order for For that, and for more complex collections, you can use a Modifier Type. If you already have a shrinking function in mind, you can also use |
One of the cases where this failed for me is a generator of a custom class ( Here's the definition of it if that helps you diagnose:
Not sure what the "underlying value type" here would be but this is built from a combination of primitive generators as you can see. |
Does |
Doubtful. How can I make that so? |
If you control the declaration of |
Perfect. Thank you! |
So, this is now working for me with an explicit |
So, we could do this, and if you think about it backwards, this is kind of how the whole shebang works. |
Ah, so then I could just call |
i.e., the version of forAll as depicted below and referring to in docs and tutorials doesn't seem to be included in the actual latest pod release:
forAll(someGenerator) { // the checker }
I was able to get:
forAllNoShrink(someGenerator) { // the checker }
to compile however.
When
someGenerator
is a fairly simple conglomeration of primitive generators, I'd image a shrinking strategy to be available and thus the former to actually compile/work. Is there something I'm missing?The text was updated successfully, but these errors were encountered: