Protect if detail is returned as None
[functest-xtesting.git] / xtesting / core / testcase.py
index f7814f7..179a568 100644 (file)
@@ -302,6 +302,8 @@ class TestCase(metaclass=abc.ABCMeta):
             path = urlparse(dst_s3_url).path.strip("/")
             dst_http_url = os.environ["HTTP_DST_URL"]
             output_str = "\n"
+            # protects if test cases return details as None
+            self.details = self.details or {}
             self.details["links"] = []
             for log_file in [self.output_log_name, self.output_debug_log_name]:
                 if os.path.exists(os.path.join(self.dir_results, log_file)):