From: yadavmr Date: Thu, 14 Nov 2019 07:23:08 +0000 (+0100) Subject: Revert "Bug 883 - Disable build failure due to stage_4 robot test results" X-Git-Tag: v7.0.0rc1~41 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F66%2F8166%2F1;p=osm%2Fdevops.git Revert "Bug 883 - Disable build failure due to stage_4 robot test results" This reverts commit 86bb9f6be89b225f10468bbb232cdb4c5968c144. Change-Id: I0fb9eb2a4e410f851ab4a74329388ae6d5836bed Signed-off-by: yadavmr --- diff --git a/jenkins/ci-pipelines/ci_stage_3.groovy b/jenkins/ci-pipelines/ci_stage_3.groovy index e37cf200..e0d6e059 100644 --- a/jenkins/ci-pipelines/ci_stage_3.groovy +++ b/jenkins/ci-pipelines/ci_stage_3.groovy @@ -93,8 +93,8 @@ def run_robot_systest(stackName,tagName,testName,envfile=null) { disableArchiveOutput : false, reportFileName : "report.html", logFileName : "log.html", - passThreshold : 0, - unstableThreshold: 0, + passThreshold : 80, + unstableThreshold: 60.0, otherFiles : "*.png", ]) } @@ -310,18 +310,16 @@ node("${params.NODE}") { stage("System Integration Test") { if ( params.DO_ROBOT ) { run_robot_systest(container_name,container_name,params.TEST_NAME,params.ROBOT_VIM) - } //else { - run_systest(container_name,container_name,"openstack_stage_4",params.HIVE_VIM_1) - //} + } else { + run_systest(container_name,container_name,"openstack_stage_4",params.HIVE_VIM_1) + } - if ( ! currentBuild.result.equals('UNSTABLE') && ! currentBuild.result.equals('FAILURE')) { + if ( ! currentBuild.result.equals('UNSTABLE') ) { stage_archive = keep_artifacts } else { - println ("Systest test failed, throwing error") - error = new Exception("Systest test failed") - currentBuild.result = 'FAILURE' - throw error - } + error = new Exception("Systest test failed") + currentBuild.result = 'FAILURE' + } } } @@ -343,11 +341,10 @@ node("${params.NODE}") { } } } - catch(Exception ex) { - error = ex + catch(caughtError) { + println("Caught error!") + error = caughtError currentBuild.result = 'FAILURE' - println("Caught error") - println(ex.getMessage()); } finally { if ( params.DO_INSTALL ) { @@ -357,6 +354,7 @@ node("${params.NODE}") { sh "docker stop ${http_server_name}" sh "docker rm ${http_server_name}" } + throw error } else { if ( !params.SAVE_CONTAINER_ON_PASS ) {