-
Notifications
You must be signed in to change notification settings - Fork 24
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 sample size incorrectly set to constant 1 #136
Comments
I think you mean that the sample size is incorrectly set to be constant (size 1!). Can you update the description? Saying "does not increase" implies the sample size increases, which is not technically correct; the sample size bounds are set (incorrectly!) and do not vary. |
Re: constant size: val sizeStep = (maxSize - minSize) / minSuccessfulTests
...
val size = minSize.toDouble + sizeStep The default parameters are:
|
Ok, is it clearer now? |
Looking at the impl which computes this |
Wow, thanks for finding this one. I'm amazed we haven't noticed this behavior until now! |
PropF.forAll { (s: String) =>
does not increase the size of the strings it is testing: it only uses strings of length 0 or 1.(The same holds for lists and presumably for alle "size-sensitive" data, i.e., not numbers.)
The apparent reason is that the loop inside of
check
implementing the quantifier uses a constant size of 1:val size = minSize.toDouble + sizeStep
.The text was updated successfully, but these errors were encountered: