Closed romain-gilles-ultra closed 3 months ago
I removed the unrelated changes I will open an other PR for those one if you are ok with that
@romain-gilles-ultra Could you please update the PR description to reflect the actual change?
@romain-gilles-ultra Could you please update the PR description to reflect the actual change?
Done
Context
I encountered an issue with the way scoverage plugin alters the dependency tree of the test module by changing its module dependency from the
outer
module to theouter.scoverage
module. This shadow modification of the dependency tree produces a side effect that impacts the IDEA configuration generation. When the IDEA configuration generation resolves the dependencies instead of using the outer module as a dependency for the test project it depends on theouter.scoverage
module which should not be generated as it does not exist factually but more virtually.Solution
Instead of modifying the dependency tree at compile-time I change it at runtime by removing the
outer.localRunClasspath()
from thetest.runClasspath()
and appending, instead, theouter.scoverage.localRunClasspath()
This resolves the issue of modifying the dependency tree but introduces one more compilation as when the
outer.localRunClasspath()
is resolved it will force the compilation of the outer module. In the previous version only theouter.scoverage
was compiled and not both of them.