Bug 1019883 - Don't populate expected field in log messages for skipped tests. r=jgraham
authorChris Manchester <cmanchester@mozilla.com>
Tue, 03 Jun 2014 16:08:53 -0400
changeset 206786 c19d5dcd5759f1b0816737f66a33fd9d7cd37be3
parent 206785 e11d8753edc0dd1a454c384d79a441193fd5d6be
child 206787 1b2acadf97b37ff48877acb80423d4c217d22b23
push id494
push userraliiev@mozilla.com
push dateMon, 25 Aug 2014 18:42:16 +0000
treeherdermozilla-release@a3cc3e46b571 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjgraham
bugs1019883
milestone32.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1019883 - Don't populate expected field in log messages for skipped tests. r=jgraham
testing/mozbase/mozlog/mozlog/structured/structuredlog.py
--- a/testing/mozbase/mozlog/mozlog/structured/structuredlog.py
+++ b/testing/mozbase/mozlog/mozlog/structured/structuredlog.py
@@ -162,17 +162,17 @@ class StructuredLogger(object):
         """
         if status.upper() not in ["PASS", "FAIL", "OK", "ERROR", "TIMEOUT",
                                   "CRASH", "ASSERT", "SKIP"]:
             raise ValueError("Unrecognised status %s" % status)
         data = {"test": test,
                 "status": status.upper()}
         if message is not None:
             data["message"] = message
-        if expected != data["status"]:
+        if expected != data["status"] and status != "SKIP":
             data["expected"] = expected
         if extra is not None:
             data["extra"] = extra
         self._log_data("test_end", data)
 
     def process_output(self, process, data, command=None):
         """Log output from a managed process.