Skip to content
This repository has been archived by the owner on Sep 17, 2024. It is now read-only.

Commit

Permalink
fix: move evaluation out of post section (#465)
Browse files Browse the repository at this point in the history
scripts are not allowed there
  • Loading branch information
mdelapenya authored Nov 25, 2020
1 parent 7fdce8b commit 3fd4896
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions .ci/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,13 @@ pipeline {
stages {
stage('Checkout') {
steps {
whenTrue(isBranch()) {
setEnvVar("REPORTER_SUFFIX", env.BRANCH_NAME)
}
whenTrue(isPR()) {
setEnvVar("REPORTER_SUFFIX", env.CHANGE_TARGET)
}

pipelineManager([ cancelPreviousRunningBuilds: [ when: 'PR' ] ])
deleteDir()
gitCheckout(basedir: BASE_DIR, githubNotifyFirstTimeContributor: true)
Expand Down Expand Up @@ -233,12 +240,6 @@ pipeline {
post {
cleanup {
githubCheckNotify(currentBuild.currentResult == 'SUCCESS' ? 'SUCCESS' : 'FAILURE')
whenTrue(isBranch()) {
setEnvVar("REPORTER_SUFFIX", env.BRANCH_NAME)
}
whenTrue(isPR()) {
setEnvVar("REPORTER_SUFFIX", env.CHANGE_TARGET)
}
notifyBuildResult(analyzeFlakey: true, flakyReportIdx: "reporter-e2e-tests-end-2-end-tests-pipeline-${env.REPORTER_SUFFIX}", prComment: true)
}
success {
Expand Down

0 comments on commit 3fd4896

Please sign in to comment.