From: Thierry Parmentelat Date: Fri, 23 Jan 2009 10:18:15 +0000 (+0000) Subject: cosmetic - sanity checks X-Git-Tag: tests-4.3-0~35 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=30c4b3ff797b7e61d91e206804053ab241b3a8fc;p=tests.git cosmetic - sanity checks --- diff --git a/system/TestNode.py b/system/TestNode.py index ed8d028..331b315 100644 --- a/system/TestNode.py +++ b/system/TestNode.py @@ -231,12 +231,16 @@ class TestNode: def check_sanity_script (self,local_script): # push the script on the node's root context + script_name=os.path.basename(local_script) + utils.header ("NODE %s : running sanity check script %s"%self.name(),script_name) ssh_handle=self.create_test_ssh() ssh_handle.copy_home(local_script) - script_name=os.path.basename(local_script) if ssh_handle.run("./"+script_name) != 0: - print "WARNING: sanity check script %s FAILED"%script_name - # xxx - temporary : always return true for now + utils.header ("WARNING: node sanity check script %s FAILED"%script_name) + print 'temporary : ignoring result and always return true for now' #return False - return True + return True + else: + utils.header ("SUCCESS: node sanity check script %s OK"%script_name) + return True diff --git a/system/TestSliver.py b/system/TestSliver.py index 815afa3..623e5e9 100644 --- a/system/TestSliver.py +++ b/system/TestSliver.py @@ -67,12 +67,16 @@ class TestSliver: return overall def check_sanity_script (self,local_script): + script_name=os.path.basename(local_script) + utils.header ("SLIVER %s : running sanity check script %s"%self.name(),script_name) ssh_handle=self.create_test_ssh() ssh_handle.copy_home(local_script) - scriptname=os.path.basename(local_script) - if ssh_handle.run("./"+scriptname) != 0: - print "WARNING: sanity check script %s FAILED"%scriptname - # xxx - temporary : ignore result and always return true for now + if ssh_handle.run("./"+script_name) != 0: + utils.header ("WARNING: sanity check script %s FAILED"%script_name) + print 'temporary : ignoring result and always return true for now' #return False - return True + return True + else: + utils.header ("SUCCESS: sliver sanity check script %s OK"%script_name) + return True