I'm using Jenkins and Ant with version 2.0.1 of the Jacoco plugin. I can't get the plugin "Record JaCoCo coverage report" post-build action to produce any reports even though it seems to be completing without errors. I wrote an ant target that creates the coverage report successfully, so if I run the ant build script with this target, Jacoco works fine. The reports are generated. However I can't figure out a way to get them into Jenkins.
Also I was under the impression that the Jenkins JaCoCo plugin generates the reports without the need for writing the report generation step into the Ant build script. Is that correct? If not, then my problem is simply that the plugin isn't finding my report files. My JaCoCo post-build action is set up as follows: Path to exe files: **/jacoco.exec Path to class directories: **/classfiles Path to source directories: **/src/main/java Inclusions: **/*.class Exclusions: Here's the plugin output in Jenkins: [JaCoCo plugin] Collecting JaCoCo coverage data... [JaCoCo plugin] **/jacoco.exec;**/classfiles;**/src/main/java; locations are configured [JaCoCo plugin] Number of found exec files for pattern **/jacoco.exec: 1 [JaCoCo plugin] Saving matched execfiles: E:\work\Tomcat\jenkins\workspace\testproject\scripts\junits\jacoco.exec [JaCoCo plugin] Saving matched class directories for class-pattern: **/classfiles: E:\work\Tomcat\jenkins\workspace\testproject\classfiles [JaCoCo plugin] Saving matched source directories for source-pattern: **/src/main/java: E:\work\Tomcat\jenkins\workspace\testproject\src\main\java [JaCoCo plugin] Loading inclusions files.. [JaCoCo plugin] inclusions: [**/*.class] [JaCoCo plugin] exclusions: [] [JaCoCo plugin] Thresholds: JacocoHealthReportThresholds [minClass=0, maxClass=0, minMethod=0, maxMethod=0, minLine=0, maxLine=0, minBranch=0, maxBranch=0, minInstruction=0, maxInstruction=0, minComplexity=0, maxComplexity=0] [JaCoCo plugin] Publishing the results.. [JaCoCo plugin] Loading packages.. [JaCoCo plugin] Done. [JaCoCo plugin] Overall coverage: class: 0, method: 0, line: 0, branch: 0, instruction: 0 ----------------------------------------------------- The source and class files and jacoco exec file all appear to be getting copied to the Jenkins build directory here: E:\work\Tomcat\jenkins\jobs\testproject\builds\37\jacoco This location contains classes, execFiles, and sources subdirectories containing the files I'd expect, but like I said, there are no reports. The reports generated by the ant build script (which work and do not show 0% coverage) are located here: E:\work\Tomcat\jenkins\workspace\testproject\scripts\jacoco Can anyone tell what's wrong? Thank you! -- Azért kapta ezt az üzenetet, mert feliratkozott a Google Csoportok szolgáltatásbeli Jenkins JaCoCo plugin mailing list csoportra. Az erről a csoportról és az ahhoz kapcsolódó e-mailekről való leiratkozáshoz küldjön egy e-amailt a(z) [email protected] címre. Ha üzenetet szeretne küldeni ebbe a csoportba, küldjön egy e-mailt a(z) [email protected] címre. További lehetőségekért látogasson el a(z) https://groups.google.com/d/optout címre.
