[
https://issues.jboss.org/browse/JBIDE-10537?page=com.atlassian.jira.plugi...
]
Mickael Istria commented on JBIDE-10537:
----------------------------------------
In short: I wasn't able to propagate the property from
jacoco:prepare-agent into surefire:test
I think that's because jacoco:prepare-agent sets a value for the test ${argLine}
property. If you set this property in the plugin, its value is overriden. A solution is to
set in the surefire <argLine>${argLine} -Dkey=value...</argLine>. At least it
works for Tycho-surefire-plugin. A more convenient way to get it working would be to be
able to "append" values to the argLine in surefire-plugin rather than replacing
it.
I've seen Nick doing this in some poms using a magic attribute for some properties,
but I did not tried it for Jacoco, I got happy with the previous solution.
The report has to be done using ant plugin, since jacoco:report only
looks into target/classes - can't go outside the current module.
Reported the same issue to Jacoco ;) You can get a single jacoco.exec file for all you
code, but the maven plugin cannot generate a single report set. It is one per module, not
readable.
Using Ant to turn jacoco.exec into report could be an additional step in CI that would be
called "materialize-reports".
But once again, let's be insistant: Sonar does all this pretty well...
Support Code Coverage with Jacoco
---------------------------------
Key: JBIDE-10537
URL:
https://issues.jboss.org/browse/JBIDE-10537
Project: Tools (JBoss Tools)
Issue Type: Enhancement
Components: Build/Releng
Affects Versions: 3.3.0.M4
Environment: any
Reporter: Mickael Istria
Assignee: Mickael Istria
Attachments: JBIDE-10537.patch
Jacoco Maven plugin allows to add very seamlessly code coverage while executing tests.
Build should leverage this and get rid of additional build steps configured for emma
plugin.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira