Skip to content
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

Regression Gen.nonEmptyBuildableOf and dependent methods since 1.14.3 #714

Closed
satorg opened this issue Nov 11, 2020 · 4 comments
Closed
Milestone

Comments

@satorg
Copy link
Contributor

satorg commented Nov 11, 2020

Consider the following example:

val nestedGen = Gen.listOf(Gen.resize(5, Gen.nonEmptyListOf(Gen.asciiChar)))

Prop
  .forAll(nestedGen, nestedGen, nestedGen, nestedGen, nestedGen, nestedGen, nestedGen, nestedGen) {
    (_, _, _, _, _, _, _, _) => true
  }
  .check()

It usually succeeds on 1.14.3, but almost always fails on 1.15.1 with errors like:

Gave up after only 43 passed tests. 501 tests were discarded.

My guess is that nonEmptyBuildableOf has changed and that made the new implementation less reliable in some cases with a few of non-empty-whatever generators with reduces max size.

See also the initial conversation here.

UPT: duplicates #708, resolved by #709.

@satorg satorg changed the title Regression Gen.nonEmptyBuildableOf and dependent methods since 1.14.4 Regression Gen.nonEmptyBuildableOf and dependent methods since 1.14.3 Nov 11, 2020
@satorg
Copy link
Contributor Author

satorg commented Nov 11, 2020

Similar issue: #581.
But it was posted for 1.14.x and it seems things became worse since then.

@ashawley ashawley added this to the 1.15.2 milestone Nov 11, 2020
@ashawley
Copy link
Contributor

It appears Erik caught this and fixed it, see #709. It didn't get merged in time to be included in 1.15.1. It will need to be released in the next version, 1.15.2.

@SethTisue
Copy link
Member

so we should close this, then?

@satorg
Copy link
Contributor Author

satorg commented Nov 11, 2020

I guess yes – looks like the fix in #709 should resolve this issue as well. Thanks for pointing it out.
Looking forward to get it released:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants