Closed ananta-code closed 1 year ago
From the screenshot it looks like you are using the deprecated step. Can you please upgrade your script, see https://plugins.jenkins.io/code-coverage-api/#plugin-content-pipeline-example for an example.
@uhafner we are using below code for java.
publishCoverage adapters: [jacocoAdapter('ci-testlogs/**/jacoco.xml')]
and for Cobertura we are using the below.
cobertura(autoUpdateHealth: false, autoUpdateStability: false, coberturaReportFile: codeCoverageFile,
conditionalCoverageTargets: '70, 0, 0', failNoReports: false, failUnhealthy: false, failUnstable: false,
lineCoverageTargets: '80, 0, 0', maxNumberOfBuilds: 0, methodCoverageTargets: '80, 0, 0', onlyStable: false,
sourceEncoding: 'ASCII', zoomCoverageChart: false)
Could you please tell what i have to use ? and also what is the plugin version it needs.
Did you have a look in the README? I linked that in my comment.
Full documentation: https://www.jenkins.io/doc/pipeline/steps/code-coverage-api/
Jenkins and plugins versions report
Environment
```text We are using jenkins Version 2.414.1 Code Coverage API plugin version 4.7.0 ``` We have an application which has Java and C++ code and we are generating code coverage report for both Java and c++. but surprisingly only the 2nd report is getting displayed in jenkins UI.Jenkins
What Operating System are you using (both controller, and any agents involved in the problem)?
CentOs 7 for both Controller and agent
Reproduction steps
Create an application having java and C++ modules and generate code coverage for both java and c++
Expected Results
Both C++ and Java reports should be generated but with the latest jenkins and code coverage Api plugin still only 1 report is getting displayed in jenkins UI and another one is empty.
Actual Results
Only 2nd report is displaying correctly and first report is empty specified in the attached screenshot
Anything else?
Only 2nd report is displaying correctly and first report is empty specified in the attached screenshots