From 293f0682dd8258a068e4b152f9fecb292d732b78 Mon Sep 17 00:00:00 2001 From: Manel Caro Date: Mon, 5 Oct 2020 11:45:41 +0200 Subject: modify finish_test call, added execution without messsage if fails --- test-cli/test/runners/simple.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test-cli/test/runners/simple.py') diff --git a/test-cli/test/runners/simple.py b/test-cli/test/runners/simple.py index ece5a4e..c110b1c 100644 --- a/test-cli/test/runners/simple.py +++ b/test-cli/test/runners/simple.py @@ -88,6 +88,7 @@ class TextTestResult(unittest.TestResult): status = "TEST_FAILED" resulttext = test.longMessage logObj.getlogger().info('{}:{}:{}:{}'.format(test.params["testidctl"], test.params["testid"], status, resulttext)) - self.__pgObj.finish_test(test.params["testidctl"], test.params["testid"], status, resulttext) + if not self.__pgObj.finish_test(test.params["testidctl"], test.params["testid"], status, resulttext): + self.__pgObj.finish_test(test.params["testidctl"], test.params["testid"], status, "") except Exception as E: logObj.getlogger().error('Exception: [{}]{}:{}:{}:{}'.format(E, test.params["testidctl"], test.params["testid"], status, resulttext)) \ No newline at end of file -- cgit v1.1