Closed
Bug 1129495
Opened 9 years ago
Closed 9 years ago
[mozlog] - Add optional path attribute to test_start
Categories
(Testing :: Mozbase, defect)
Tracking
(firefox38 fixed)
RESOLVED
FIXED
mozilla38
Tracking | Status | |
---|---|---|
firefox38 | --- | fixed |
People
(Reporter: jgraham, Assigned: ahal)
References
Details
Attachments
(1 file, 1 obsolete file)
This attribute is to hold the path of the file containing the test when it is known and different from the URL. The base of this path is undefined (it will typically be the root of the source tree).
Assignee | ||
Comment 1•9 years ago
|
||
I was looking into this and seems like there's nothing to do other than update the documentation since afaict consumers can already add arbitrary keys to the log data. James is that correct?
Flags: needinfo?(james)
Reporter | ||
Comment 2•9 years ago
|
||
I think a patch would look something like (totally untested, written in the last 2 minutes): diff --git a/testing/mozbase/mozlog/mozlog/structured/structuredlog.py b/testing/mozbase/mozlog/mozlog/structured/structuredlog.py index 4fadc9b..fe7ea2e 100644 --- a/testing/mozbase/mozlog/mozlog/structured/structuredlog.py +++ b/testing/mozbase/mozlog/mozlog/structured/structuredlog.py @@ -249,10 +249,12 @@ class StructuredLogger(object): self._log_data("suite_end") @log_action(TestId("test")) + @log_action(Unicode("path", default=None, optional=True)) def test_start(self, data): """Log a test_start message :param test: Identifier of the test that will run. + :param path Path to the test relative to some base (typically the root of the source tree) """ if not self._state.suite_started: self.error("Got test_start message before suite_start for test %s" %
Flags: needinfo?(james)
Assignee | ||
Comment 3•9 years ago
|
||
Thanks, I missed that. I'll test it out, update the docs and flag you for review.
Assignee: nobody → ahalberstadt
Status: NEW → ASSIGNED
Assignee | ||
Comment 4•9 years ago
|
||
/r/3679 - Bug 1129495 - [mozlog] Add optional 'path' attribute to test_start, r=jgraham Pull down this commit: hg pull review -r 4578472c6be3108787c90277c9fb1950ee66b311
Assignee | ||
Comment 5•9 years ago
|
||
Comment on attachment 8562348 [details] MozReview Request: bz://1129495/ahal /r/3679 - Bug 1129495 - [mozlog] Add optional 'path' attribute to test_start, r=jgraham Pull down this commit: hg pull review -r 0c1ea4412649a5e2990b5ffad739fda22fa2c48f
Attachment #8562348 -
Flags: review?(james)
Reporter | ||
Comment 6•9 years ago
|
||
Comment on attachment 8562348 [details] MozReview Request: bz://1129495/ahal https://reviewboard.mozilla.org/r/3677/#review2909 ::: testing/mozbase/mozlog/mozlog/structured/structuredlog.py (Diff revision 1) > :param test: Identifier of the test that will run. Should probably be documented again here.
Attachment #8562348 -
Flags: review?(james)
Assignee | ||
Comment 7•9 years ago
|
||
https://reviewboard.mozilla.org/r/3677/#review2911 > Should probably be documented again here. I did, make sure you have the full diff selected because I forgot to do this in my original push, but did a quick follow up immediately after.
Reporter | ||
Comment 8•9 years ago
|
||
Comment on attachment 8562348 [details] MozReview Request: bz://1129495/ahal https://reviewboard.mozilla.org/r/3677/#review2913 Ship It!
Attachment #8562348 -
Flags: review+
Assignee | ||
Comment 9•9 years ago
|
||
Little try run: https://treeherder.mozilla.org/#/jobs?repo=try&revision=57ef79ca8f38 Landed: https://hg.mozilla.org/integration/mozilla-inbound/rev/bdc679c02e3b
Comment 10•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/bdc679c02e3b
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
status-firefox38:
--- → fixed
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
Assignee | ||
Comment 11•9 years ago
|
||
Attachment #8562348 -
Attachment is obsolete: true
Attachment #8619317 -
Flags: review+
Assignee | ||
Comment 12•9 years ago
|
||
You need to log in
before you can comment on or make changes to this bug.
Description
•