-
Notifications
You must be signed in to change notification settings - Fork 157
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
Package / file exclusion does not work with Scala 3 #525
Comments
Hey @kyri-petrou, this is actually a limitation in the implementation of how coverage works with Scala 3. You can read more about it here. So it'd need to be added upstream in order for this to work. |
@ckipp01 aghh I see. Thanks! |
I created an MR to address the issue. It would benefit from the upstream changes, but it is not required. Coverage data can be filtered after it was collected. |
What is an "MR"? |
hey @ivanobulo I just tried release
Wondering if I could be missing something else? EDIT: thank you so much for the fix 🙂 |
Could someone kindly explain me how can i exclude an entire package and all its subpackages from the scoverage report on Scala 3.4? |
https://docs.scala-lang.org/overviews/compiler-options/index.html and i just added this flag:
|
@ckipp01 is upstream now fixed? Can we proceed implementing the fix that passes the proper flag to the compiler? |
Scala 3 supports file and class/package exclusions since 3.4.2 |
Yes, I believe this is fixed, but I also haven't been following. Please do submit a PR for it. |
@jozic can you work on a PR for sbt-scoverage too please :D ? I would do that but I assume you're more proficient with it given that you did it for maven :) |
Hi there. There seems that some coverage settings (primarily
coverageExcludedPackages
andcoverageExcludedFiles
, but I believe some other ones might be affected) are not working with Scala 3.The easiest way to reproduce is by cloning the sbt-scoverage-samples repo, adding the following line to
build.sbt
:and then running
This yields the following:
Scala 2:
Scala 3:
The text was updated successfully, but these errors were encountered: