Closed Bug 1275926 Opened 3 years ago Closed Last year
[mozlog] Add test result grouping formatter from servo
58 bytes, text/x-review-board-request
This is designed to just show which tests are running and only produce output corresponding to the tests that failed. It's the default formatter for servo, and this is just upstreaming it into mozlog (with a few minor changes to work better without multiple simultaneous test processes).
This is designed to produce minimal output; just show which tests are running and then provide details at the end for tests that gave an unexpected result. Review commit: https://reviewboard.mozilla.org/r/55468/diff/#index_header See other reviews: https://reviewboard.mozilla.org/r/55468/
Attachment #8756891 - Flags: review?(ahalberstadt)
Comment on attachment 8756891 [details] MozReview Request: Bug 1275926 - Upstream grouping mozlog formatter from Servo, r=ahal https://reviewboard.mozilla.org/r/55468/#review52230 Cool! ::: testing/mozbase/mozlog/mozlog/formatters/grouping.py:54 (Diff revision 1) > + def get_move_up_and_clear_eol_codes(self): > + try: > + import blessings > + except ImportError: > + return DEFAULT_MOVE_UP_CODE, DEFAULT_CLEAR_EOL_CODE > + > + try: > + self.terminal = blessings.Terminal() > + return self.terminal.move_up, self.terminal.clear_eol > + except Exception as exception: > + sys.stderr.write("GroupingFormatter: Could not get terminal " > + "control characters: %s\n" % exception) > + return DEFAULT_MOVE_UP_CODE, DEFAULT_CLEAR_EOL_CODE This seems pretty heavy handed to get two hardcoded strings: https://github.com/erikrose/blessings/blob/master/blessings/__init__.py#L130 Why not just put 'cuu1' and 'el' directly in the DEFAULT\_\* at the top? ::: testing/mozbase/mozlog/mozlog/formatters/grouping.py:119 (Diff revision 1) > + new_display=self.build_status_line()) > + > + def wrap_and_indent_lines(self, lines, indent): > + assert(len(lines) > 0) > + > + output = indent + u"\u25B6 %s\n" % lines I'd add: from \_\_future\_\_ import unicode_literals Rather than putting u'' in half the places and forgetting it in the other half.
Attachment #8756891 - Flags: review?(ahalberstadt) → review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/mozilla-inbound/rev/4ee6bd59c115 Upstream grouping mozlog formatter from Servo, r=ahal https://hg.mozilla.org/integration/mozilla-inbound/rev/0d5f2da0dce7 Fixup a missing return statement in wpt logging setup, r=me
Backed out 2 changesets (Bug 1275926) for linting failure on grouping.py. Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/073c574eccc040d44bd1a3ac6354cbe9e47f63ea Push with failures: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&resultStatus=pending,running,success,testfailed,busted,exception&revision=0d5f2da0dce734f2c16d988474a81c57cd0c9f24&selectedJob=204199730 Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=204199730&repo=mozilla-inbound&lineNumber=280
Pushed by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/eab20dd50c4c Upstream grouping mozlog formatter from Servo, r=ahal https://hg.mozilla.org/integration/mozilla-inbound/rev/8b5926fac04e Fixup a missing return statement in wpt logging setup, r=me
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/13433 for changes under testing/web-platform/tests
Upstream PR was closed without merging
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
Upstream PR merged
Can't merge web-platform-tests PR due to failing upstream checks: Github PR https://github.com/web-platform-tests/wpt/pull/13433 * Taskcluster (pull_request) (https://tools.taskcluster.net/task-group-inspector/#/IvgNbX78TEer_KrRzD7cHw)
You need to log in before you can comment on or make changes to this bug.