bug fix: no status returned at the end of a Tempest/Rally run
authorMorgan Richomme <morgan.richomme@orange.com>
Thu, 2 Feb 2017 09:06:59 +0000 (10:06 +0100)
committerMorgan Richomme <morgan.richomme@orange.com>
Thu, 2 Feb 2017 09:06:59 +0000 (10:06 +0100)
the return shall only deal with test executed or not
it shall not return the criteria through a return statement
the criteria is managed with the criteria field
previous patch https://gerrit.opnfv.org/gerrit/#/c/27807
corrected the fact that we should not return the status of the test
which was preventing Failed results to be pushed
but it removed the return needed statement

JIRA: FUNCTEST-714

Change-Id: I3d4c609467837e4ce2353c67c0b8ea95e21ebd84
Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
functest/opnfv_tests/openstack/rally/rally.py
functest/opnfv_tests/openstack/tempest/tempest.py

index a2a7e5c..f984c36 100644 (file)
@@ -530,6 +530,10 @@ class RallyBase(testcase_base.TestcaseBase):
             return testcase_base.TestcaseBase.EX_RUN_ERROR
         self.stop_time = time.time()
 
             return testcase_base.TestcaseBase.EX_RUN_ERROR
         self.stop_time = time.time()
 
+        # If we are here, it means that the test case was successfully executed
+        # criteria is managed by the criteria Field
+        return testcase_base.TestcaseBase.EX_OK
+
 
 class RallySanity(RallyBase):
     def __init__(self):
 
 class RallySanity(RallyBase):
     def __init__(self):
index 2bdbe47..17a907e 100644 (file)
@@ -281,6 +281,10 @@ class TempestCommon(testcase_base.TestcaseBase):
 
         self.stop_time = time.time()
 
 
         self.stop_time = time.time()
 
+        # If we are here, it means that the test case was successfully executed
+        # criteria is managed by the criteria Field
+        return testcase_base.TestcaseBase.EX_OK
+
 
 class TempestSmokeSerial(TempestCommon):
 
 
 class TempestSmokeSerial(TempestCommon):