Fix for tests posting to Confluence
Change-Id: I386c8dda6b4f60996aaa8e35a8812e78a1c75826
diff --git a/TestON/JenkinsFile/CommonJenkinsFile.groovy b/TestON/JenkinsFile/CommonJenkinsFile.groovy
index 2edc09d..0383318 100644
--- a/TestON/JenkinsFile/CommonJenkinsFile.groovy
+++ b/TestON/JenkinsFile/CommonJenkinsFile.groovy
@@ -261,6 +261,13 @@
cd'''
}
+def isPostingResult( manual, postresult ){
+ // check if it is posting the result.
+ // posting when it is automatically running or has postResult condition from the manual run
+
+ return manual == "false" || postresult == "true"
+}
+
def publishToConfluence( isManualRun, isPostResult, wikiLink, file ){
// publish HTML script to wiki confluence
// isManualRun : string "true" "false"
@@ -314,6 +321,7 @@
( resultURL != "" ? ( "\n[Karaf log] : \n" +
resultURL + "artifact/" ) : "" ),
teamDomain: 'onosproject' )
+ print "Abnormal test result."
throw new Exception( "Abnormal test result." )
}
else {