[oe-commits] [openembedded-core] 06/12: oeqa/core/runner: Don't add empty log entries

git at git.openembedded.org git at git.openembedded.org
Mon Oct 29 14:07:22 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit 7b1dad3acd410c4263b21e28d85a0c779e3cac86
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Mon Oct 29 13:48:14 2018 +0000

    oeqa/core/runner: Don't add empty log entries
    
    There is no point in adding empty log entries to the json result files, only
    add them if there is log data.
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/lib/oeqa/core/runner.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/meta/lib/oeqa/core/runner.py b/meta/lib/oeqa/core/runner.py
index d6d5afe..67756c3 100644
--- a/meta/lib/oeqa/core/runner.py
+++ b/meta/lib/oeqa/core/runner.py
@@ -139,7 +139,10 @@ class OETestResult(_TestResult):
                 t = " (" + "{0:.2f}".format(self.endtime[case.id()] - self.starttime[case.id()]) + "s)"
 
             self.tc.logger.info("RESULTS - %s - Testcase %s: %s%s" % (case.id(), oeid, status, t))
-            result[case.id()] = {'status': status, 'log': log}
+            if log:
+                result[case.id()] = {'status': status, 'log': log}
+            else:
+                result[case.id()] = {'status': status}
 
         if json_file_dir:
             tresultjsonhelper = OETestResultJSONHelper()

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list