diff --git a/src/com/mirantis/mk/SaltModelTesting.groovy b/src/com/mirantis/mk/SaltModelTesting.groovy
index 5bba09b..6415d55 100644
--- a/src/com/mirantis/mk/SaltModelTesting.groovy
+++ b/src/com/mirantis/mk/SaltModelTesting.groovy
@@ -7,7 +7,7 @@
  * @param extraFormulas       extraFormulas to install
  * @param formulasSource      formulas source (git or pkg)
  * @param testDir             directory of model
- * @param formulasSource      Salt formulas source type (optional, default pkg)  
+ * @param formulasSource      Salt formulas source type (optional, default pkg)
  * @param formulasRevision    APT revision for formulas (optional default stable)
  */
 
@@ -43,38 +43,35 @@
       is_mk_ci = false
     }
 
-    wrap([$class: 'AnsiColorBuildWrapper']) {
-      if (!imageFound) {
-        sh("apt-get update && apt-get install -y curl subversion git python-pip sudo python-pip python-dev zlib1g-dev git")
-        sh("pip install git+https://github.com/epcim/reclass.git@pr/fix/fix_raise_UndefinedVariableError")
-      }
-      sh("mkdir -p /srv/salt/ || true")
-      sh("cp -r ${testDir} /srv/salt/reclass")
-      sh("svn export --force https://github.com/salt-formulas/salt-formulas/trunk/deploy/scripts /srv/salt/scripts")
-      sh("git config --global user.email || git config --global user.email 'ci@ci.local'")
-      sh("git config --global user.name || git config --global user.name 'CI'")
+    if (!imageFound) {
+      sh("apt-get update && apt-get install -y curl subversion git python-pip sudo python-pip python-dev zlib1g-dev git")
+      sh("pip install git+https://github.com/epcim/reclass.git@pr/fix/fix_raise_UndefinedVariableError")
+    }
+    sh("mkdir -p /srv/salt/ || true")
+    sh("cp -r ${testDir} /srv/salt/reclass")
+    sh("svn export --force https://github.com/salt-formulas/salt-formulas/trunk/deploy/scripts /srv/salt/scripts")
+    sh("git config --global user.email || git config --global user.email 'ci@ci.local'")
+    sh("git config --global user.name || git config --global user.name 'CI'")
 
-      withEnv(["FORMULAS_SOURCE=${formulasSource}", "EXTRA_FORMULAS=${extraFormulas}", "DISTRIB_REVISION=${formulasRevision}", "DEBUG=1", "MASTER_HOSTNAME=${masterName}", "MINION_ID=${masterName}", "HOSTNAME=cfg01", "DOMAIN=mk-ci.local"]){
-          sh("bash -c 'echo $MASTER_HOSTNAME'")
-          sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && system_config'")
-          sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && saltmaster_bootstrap'")
-          sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && saltmaster_init'")
+    withEnv(["FORMULAS_SOURCE=${formulasSource}", "EXTRA_FORMULAS=${extraFormulas}", "DISTRIB_REVISION=${formulasRevision}", "DEBUG=1", "MASTER_HOSTNAME=${masterName}", "MINION_ID=${masterName}", "HOSTNAME=cfg01", "DOMAIN=mk-ci.local"]){
+        sh("bash -c 'echo $MASTER_HOSTNAME'")
+        sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && system_config'")
+        sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && saltmaster_bootstrap'")
+        sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && saltmaster_init'")
 
-          if (!is_mk_ci) {
-             sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && verify_salt_minions'")
-          }
-      }
+        if (!is_mk_ci) {
+           sh("bash -c 'source /srv/salt/scripts/salt-master-init.sh; cd /srv/salt/scripts && verify_salt_minions'")
+        }
+    }
 
-      if (is_mk_ci) {
-        def nodes = sh script: "find /srv/salt/reclass/nodes -name '*.yml' | grep -v 'cfg*.yml'", returnStdout: true
-        for (minion in nodes.tokenize()) {
-          def basename = sh script: "basename ${minion} .yml", returnStdout: true
-          if (!basename.trim().contains(masterName)) {
-            testMinion(basename.trim())
-          }
+    if (is_mk_ci) {
+      def nodes = sh script: "find /srv/salt/reclass/nodes -name '*.yml' | grep -v 'cfg*.yml'", returnStdout: true
+      for (minion in nodes.tokenize()) {
+        def basename = sh script: "basename ${minion} .yml", returnStdout: true
+        if (!basename.trim().contains(masterName)) {
+          testMinion(basename.trim())
         }
       }
-
     }
   }
 }
