Skip to content

Conversation

@patrick-premont
Copy link

Restored the ability to enable coverage within the project description with coverageEnabled.

Made the libraryDependencies setting depend on coverageEnabled, so as to simplify the implementation of the coverage command.

Runtime is no longer just a 'provided' dependency of a coverage-enabled project.

…n with coverageEnabled.

Made the libraryDependencies setting depend on coverageEnabled, so as to simplify the implementation of the coverage command.

Runtime is no longer just a 'provided' dependency of a coverage-enabled project.
@patrick-premont
Copy link
Author

Documentation changes depend on plugin PR scoverage/scalac-scoverage-plugin#162

@gslowikowski
Copy link
Member

I've tested your PR with sequences like:
sbt clean coverage publishLocal
sbt clean coverage compile coverageOff publishLocal
sbt clean coverage compile coverageOff compile coverage publishLocal
and it seems to work properly. Instrumented/uninstrumented classes in jar file and scalac-scoverage-runtime dependency present/absent in published ivy/pom file.

Can you tell me, how it works and if this is recommended way to toggle dependencies dynamically or your idea? Maybe some links? Thanks.

BTW.
It's good that you removed provided scope. If for some reason (or accidentally) instrumented classes will be deployed, scalac-scoverage-runtime dependency should be active in run time.

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

Successfully merging this pull request may close these issues.

2 participants