From 6fd9cb130919adf085e4c96a305b018da601288f Mon Sep 17 00:00:00 2001 From: John Blum Date: Mon, 30 Apr 2018 15:26:28 -0700 Subject: [PATCH] Change conditional logic for determining 'SUCCESS'. --- Jenkinsfile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index c20fd32..66f024e 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,7 +7,7 @@ properties(projectProperties) def SUCCESS = hudson.model.Result.SUCCESS.toString() -currentBuild.result = SUCCESS +currentBuild.result = 'UNKNOWN' try { parallel check: { @@ -16,6 +16,7 @@ try { checkout scm try { sh "./gradlew clean check --refresh-dependencies --no-daemon" + currentBuild.result = SUCCESS } catch (Exception cause) { currentBuild.result = 'FAILED: check' @@ -28,7 +29,7 @@ try { } } - if (currentBuild.result == 'SUCCESS') { + if (currentBuild.result.equals(SUCCESS)) { parallel artifacts: { stage('Deploy Artifacts') { node {