diff --git a/script/local.py b/script/local.py index 44d25ed..96262a9 100644 --- a/script/local.py +++ b/script/local.py @@ -27,15 +27,17 @@ class TestingTool: return None #print/log information - #test = the string to be printed/logged + #text = the string to be printed/logged def log(self, text): import time time.ctime() now = time.strftime('%Y.%m.%d %H:%M:%S') logText = self.deviceName + ' - ' + self.testName + ': ' + str(text) print now + ' ' + logText - log(logText) - + try: + log(logText) + except: + #prepare and send feedback to calling tool # returnString = the string containing info on the test result # testPassed = true if the test was successful, false if test had a problem diff --git a/script/tests/tests/PS Tests/test without ioc/test without ioc.py b/script/tests/tests/PS Tests/test without ioc/test without ioc.py index 701c8c5..0483998 100644 --- a/script/tests/tests/PS Tests/test without ioc/test without ioc.py +++ b/script/tests/tests/PS Tests/test without ioc/test without ioc.py @@ -126,9 +126,8 @@ def startTest(testName, DEVICE, params): #IMPORTANT: if the test was successful, write the report into the variables ret and success. #for example, write the following: - ret = "Example - Test successful, here some detail: ..." - success = True - test.sendFeedback(ret, success) + ret = "Example Test successful" + success = True #once the test is finished, no need to do anything. The code below yours will do the rest. ################ End of Example ##########