jenkinsci / jenkinsci/github-pr-coverage-status-plugin

Unknown parameter(s) found for class type 'com.github.terma.jenkins.githubprcoveragestatus.CompareCoverageAction': jacocoCounterType

Open
#81 0 comments 2 reactions 0 assignees View on GitHub
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

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.