Skip to content

Commit

Permalink
Record RuboCop issues for Katello
Browse files Browse the repository at this point in the history
This changes the invocation to directly call RuboCop instead of relying
on a rake task. This is copied from smart-proxy.groovy.

Interstingly enough, it doesn't use the katello:rubocop:jenkins task
that also exists.
  • Loading branch information
ekohl committed Jan 5, 2024
1 parent a68120f commit c84e5eb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
7 changes: 6 additions & 1 deletion theforeman.org/pipelines/test/foreman/katello.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,12 @@ pipeline {
stage('rubocop') {
steps {
dir('foreman') {
withRVM(['bundle exec rake katello:rubocop TESTOPTS="-v" --trace'], ruby)
withRVM(["bundle exec rubocop --format progress --out ${env.WORKSPACE}/rubocop.log --format progress ${env.WORKSPACE}"], ruby)
}
}
post {
always {
recordIssues tool: ruboCop(pattern: "${env.WORKSPACE}/rubocop.log"), enabledForFailure: true
}
}
}
Expand Down
7 changes: 6 additions & 1 deletion theforeman.org/pipelines/test/testKatello.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,12 @@ pipeline {
stage('rubocop') {
steps {
dir('foreman') {
withRVM(['bundle exec rake katello:rubocop TESTOPTS="-v" --trace'], ruby)
withRVM(["bundle exec rubocop --format progress --out ${env.WORKSPACE}/rubocop.log --format progress ${env.WORKSPACE}"], ruby)
}
}
post {
always {
recordIssues tool: ruboCop(pattern: "${env.WORKSPACE}/rubocop.log"), enabledForFailure: true
}
}
}
Expand Down

0 comments on commit c84e5eb

Please sign in to comment.