Improved kitchen tests logging
Change-Id: I96c62d0ed4c16e79a8884d5a579768eb5fdf6d15
diff --git a/test-salt-formulas-pipeline.groovy b/test-salt-formulas-pipeline.groovy
index e862498..c6e5ce0 100644
--- a/test-salt-formulas-pipeline.groovy
+++ b/test-salt-formulas-pipeline.groovy
@@ -26,7 +26,7 @@
def checkouted = false;
-node("python") {
+node("python&&docker") {
try{
stage("checkout") {
if (gerritRef) {
@@ -51,7 +51,7 @@
}
stage("kitchen") {
if (fileExists(".kitchen.yml")) {
- common.infoMsg(".kitchen.yml found running kitchen tests")
+ common.infoMsg(".kitchen.yml found, running kitchen tests")
ruby.ensureRubyEnv()
ruby.installKitchen()
wrap([$class: 'AnsiColorBuildWrapper']) {
@@ -66,6 +66,10 @@
currentBuild.result = "FAILURE"
throw e
} finally {
+ if(currentBuild.result == "FAILURE" && fileExists(".kitchen/logs/kitchen.log")){
+ println("KITCHEN LOG:")
+ println readFile(".kitchen/logs/kitchen.log")
+ }
common.sendNotification(currentBuild.result,"",["slack"])
}
}
\ No newline at end of file