summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPedro Alvarez <pedro.alvarez@codethink.co.uk>2015-09-25 14:58:49 +0000
committerPedro Alvarez <pedro.alvarez@codethink.co.uk>2015-09-25 14:58:49 +0000
commitb00e49b1a4624de39ae81f44d3256bf361279a8c (patch)
tree2132ecb1b27d02cdab040e94e3b362582472da05
parentaaf2f4112dd62beefca8de7d17afc38178d8c6ee (diff)
downloadciat-tester-b00e49b1a4624de39ae81f44d3256bf361279a8c.tar.gz
Skip tests when system wasn't definied
-rwxr-xr-xtester8
1 files changed, 6 insertions, 2 deletions
diff --git a/tester b/tester
index ac0de6a..6d368ce 100755
--- a/tester
+++ b/tester
@@ -379,8 +379,12 @@ class ReleaseApp(cliapp.Application):
for system in step['systems']:
# TODO: Get user for each command from test file
# TODO: Pass prefix, so systems can talk to each other
- s = self.systems[system]
- s.runcmd(['sh', '-c', cmd], 'root')
+ try:
+ s = self.systems[system]
+ except KeyError:
+ print "WARNING: System " + system + " not defined, ignoring test"
+ else:
+ s.runcmd(['sh', '-c', cmd], 'root')
def clean_up(self):
print('[Local] Clean up systems on remote hosts:')