jenkinsci / jenkinsci/github-pr-coverage-status-plugin
Unknown parameter(s) found for class type 'com.github.terma.jenkins.githubprcoveragestatus.CompareCoverageAction': jacocoCounterType
- Dominant language
- Java
- Stars
- 97
- Forks
- 101
- PR merge metrics
- No merged PRs in 30d
Description
We see:
```
Unknown parameter(s) found for class type 'com.github.terma.jenkins.githubprcoveragestatus.CompareCoverageAction': jacocoCounterType
```
when using documented approach from [README.md](https://github.com/jenkinsci/github-pr-coverage-status-plugin/blob/master/README.md#how-to-use-with-jenkins-pipelines):
```
if ('SUCCESS' == currentBuild.currentResult) {
currentBuild.result = 'SUCCESS'
step([$class: 'CompareCoverageAction', jacocoCounterType: 'INSTRUCTION', publishResultAs: 'comment', scmVars: [GIT_URL: env.GIT_URL]])
}
```
If we simply replace `jacocoCounterType` with `jacocoCoverageCounter` ([reference in CompareCoverageAction class](https://github.com/jenkinsci/github-pr-coverage-status-plugin/blob/master/src/main/java/com/github/terma/jenkins/githubprcoveragestatus/CompareCoverageAction.java#L66)) the warning is not shown.
Note: problem is only with `CompareCoverageAction`. All works as expected for `MasterCoverageAction` though.
I assume if `CompareCoverageAction` class is changed it might break current setup that some are using. It makes sense to fix the `README.md` though since currently it's a bug in documentation. Please fix.
Contributor guide
Assessment
This issue has not been assessed yet.