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

Update discipline-scalatest #3259

Merged

Conversation

travisbrown
Copy link
Contributor

@travisbrown travisbrown commented Jan 17, 2020

Okay, trying this again, with 1.0.0-RC4.


Update: the NPEs were because of an initialization issue in cats.kernel.laws.Test, which was happening because the implicit PropertyCheckConfiguration is now being resolved where checkAll is called instead of in discipline-scalatest (where previously it always used generatorDrivenConfig).

Unfortunately ScalaTest's org.scalatest.prop.Configuration defines generatorDrivenConfig as a val, so we can't just slap a lazy on the override. Instead I've added a configuration class that makes the initialization work out right.

This is the only place this issue showed up either here or in Circe, which I've also updated to discipline-scalatest 1.0.0-RC4, and I think it's likely to be rare—it's only showing up here because of the kind of unusual arrangement of Scala-version-specific tests.

I also think the new behavior is the correct behavior. If the user was writing tests in terms of check directly, the implicit configuration would be resolved at the point where they call check—it wouldn't just use generatorDrivenConfig automatically. In my view our checkAll should do the same.

(I'll note the issue in the final 1.0.0 release notes.)

@travisbrown
Copy link
Contributor Author

Will look at the 2.13 failures in the morning.

@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (master@2018c75). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #3259   +/-   ##
=========================================
  Coverage          ?   93.41%           
=========================================
  Files             ?      372           
  Lines             ?     7241           
  Branches          ?      183           
=========================================
  Hits              ?     6764           
  Misses            ?      477           
  Partials          ?        0
Flag Coverage Δ
#scala_version_212 93.41% <ø> (?)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2018c75...a61df99. Read the comment docs.

@travisbrown travisbrown merged commit 1759d5b into typelevel:master Jan 18, 2020
@travisbrown travisbrown added this to the 2.2.0-M1 milestone Jan 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants