diff options
Diffstat (limited to 'vars/utils.groovy')
-rw-r--r-- | vars/utils.groovy | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/vars/utils.groovy b/vars/utils.groovy index d6ee25c..c37ea21 100644 --- a/vars/utils.groovy +++ b/vars/utils.groovy @@ -367,7 +367,13 @@ def run(configs, concurrent = true) { try { stage("Test (${myconfig.name})") { for (cmd in myconfig.test_cmds) { - sh(script: cmd) + // Ignore status code from all commands in + // test_cmds so Jenkins will always make it + // to the post-build stage. + // This accommodates tools like pytest returning + // !0 codes when a test fails which would + // abort the job too early. + sh(script: "${cmd} || true") } } } |