-
Notifications
You must be signed in to change notification settings - Fork 126
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
Any plan to support incremental compilation? #492
Comments
Thanks for the report @crakjie. Could you explain a bit more of your workflow? Typically scoverage shouldn't be enabled while developing where continual incremental compilations is happening. Rather the flow is typically that coverage is enabled, which will force a full recompile and then the tests run, a report is generated, and coverage is disabled. Could you outline how you're using scoverage? |
The idea is to benefit from incremental compilation even in the CI process. But, as you guess, scoverage is cleaning the I also have problem with the |
@crakjie I'm not sure if you have the same problem as I do, but I found this workaround that works well for my team: scoverage/sbt-scoverage#309 (comment) |
Describe the bug
Currently every time a compilation is done the
datadir
is cleaned. Then thescoverage.coverage
is regenerated only with the compiled satements. So when the report is then generated it contains only the coverage for few statements.It happens after incremental compilation, it happen when pulling sbt remote cache, it also happen when source files are regenerated for every build (ie file generated by https://github.com/sbt/sbt-buildinfo).
I'm not saying that having the coverage for only what was recompiled is useless. A merge request could show the percentage of coverage of it's added lines.
But for project using generated source it's make it impossible to extract coverage as that compilation of generated file are done sperately.
Expected behavior
Re-calculate the
scoverage.coverage
for the whole source code instead, or at least having the option to do so.I think the already compiled code would not have to be re-instrumented because it was already done in the previous compilations.
What build tool are you using?
sbt
Version of scoverage
1.4.11
The text was updated successfully, but these errors were encountered: