Closed
Bug 889076
Opened 11 years ago
Closed 11 years ago
use the profile dir to store minidumps in the crashreporter xpcshell tests
Categories
(Toolkit :: General, defect)
Tracking
()
RESOLVED
FIXED
mozilla25
Tracking | Status | |
---|---|---|
firefox25 | --- | fixed |
People
(Reporter: mihneadb, Assigned: mihneadb)
References
Details
(Whiteboard: [qa-])
Attachments
(1 file, 5 obsolete files)
4.82 KB,
patch
|
ted
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•11 years ago
|
||
still need to figure out the test in unit_ipc. The others work fine.
Assignee: nobody → mihneadb
Comment 3•11 years ago
|
||
Could you clarify what's not working and what you're trying to achieve?
Flags: needinfo?(josh)
Assignee | ||
Comment 4•11 years ago
|
||
I want to run all xpcshell tests concurrently. For the crashreporter tests, this meant changing the path where the minidump is stored to the profile dir, since every test has its own profile dir, while cwd is the same for all of them.
This change works for all the tests except for the one in unit_ipc,
Comment 5•11 years ago
|
||
And how does the failure manifest for the tests in unit_ipc?
Assignee | ||
Comment 6•11 years ago
|
||
:jdm, I attached the log.
Comment 7•11 years ago
|
||
Ok, so the symptom is that no minidump is found in the profile directory (the log helpfully obscures this due to bug 890677).
Assignee | ||
Comment 8•11 years ago
|
||
Right, and it has something to do with the fact that this is run in a new process, I guess. It is the only difference, the others work.
You can just apply the patch from bug 887054 and try it yourself.
Comment 9•11 years ago
|
||
Interestingly enough, when I pasted the "get the profile dir" snippet into a random xpcshell test that runs in a content process, it threw an error because profd is redeclared. Try renaming it and see if anything changes?
Assignee | ||
Comment 10•11 years ago
|
||
Attachment #769830 -
Attachment is obsolete: true
Attachment #771805 -
Attachment is obsolete: true
Attachment #772367 -
Flags: review?(ted)
Comment 11•11 years ago
|
||
Comment on attachment 772367 [details] [diff] [review]
use the profile dir
Review of attachment 772367 [details] [diff] [review]:
-----------------------------------------------------------------
I kind of wish we had a do_get_tempdir() that returned the same directory but didn't set up the profile directory service provider, since tests like these don't actually need it, but it's not actively harmful.
::: toolkit/crashreporter/test/unit/crasher_subprocess_head.js
@@ +6,5 @@
> +// get the profile dir
> +let env = Components.classes["@mozilla.org/process/environment;1"].getService(Components.interfaces.nsIEnvironment);
> +let file = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);
> +file.initWithPath(env.get("XPCSHELL_TEST_PROFILE_DIR"));
> +let _profd = file;
You could just s/file/profd/ and drop the second variable assignment.
Attachment #772367 -
Flags: review?(ted) → review+
Assignee | ||
Comment 12•11 years ago
|
||
Assignee | ||
Comment 13•11 years ago
|
||
Comment on attachment 772816 [details] [diff] [review]
use the profile dir
updated
Attachment #772816 -
Flags: review+
Assignee | ||
Updated•11 years ago
|
Attachment #772367 -
Attachment is obsolete: true
Assignee | ||
Comment 14•11 years ago
|
||
Assignee | ||
Comment 15•11 years ago
|
||
Not sure if I should also make this change in the crashreporter tests themselves.
It seems like it's enough to do it in the xpcshell/head.js file.
Attachment #773471 -
Flags: review?(ted)
Assignee | ||
Updated•11 years ago
|
Attachment #772816 -
Attachment is obsolete: true
Assignee | ||
Comment 16•11 years ago
|
||
(In reply to Mihnea Dobrescu-Balaur (:mihneadb) from comment #15)
> Created attachment 773471 [details] [diff] [review]
> use the new do_get_tempdir method in head.js
>
> Not sure if I should also make this change in the crashreporter tests
> themselves.
> It seems like it's enough to do it in the xpcshell/head.js file.
Actually we don't even have access to head.js in crasher_subprocess_head.js.
Comment 17•11 years ago
|
||
Yeah, not really worthwhile, the subprocess isn't actually running xpcshell tests, it's just there to crash.
Assignee | ||
Comment 18•11 years ago
|
||
Attachment #773556 -
Flags: review?(ted)
Assignee | ||
Updated•11 years ago
|
Attachment #773471 -
Attachment is obsolete: true
Attachment #773471 -
Flags: review?(ted)
Comment 19•11 years ago
|
||
Comment on attachment 773556 [details] [diff] [review]
changed to the new do_get_tempdir() implementation
Review of attachment 773556 [details] [diff] [review]:
-----------------------------------------------------------------
Nice, thanks!
Attachment #773556 -
Flags: review?(ted) → review+
Assignee | ||
Comment 20•11 years ago
|
||
Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Comment 21•11 years ago
|
||
Flags: in-testsuite-
Keywords: checkin-needed
Comment 22•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
Comment 23•11 years ago
|
||
I missed it in review, but this patch broke getting crash stacks for xpcshell tests :-( I pushed a fix:
https://hg.mozilla.org/integration/mozilla-inbound/rev/971beabe0237
Updated•11 years ago
|
Whiteboard: [checkin-needed-aurora]
Comment 24•11 years ago
|
||
Comment 25•11 years ago
|
||
status-firefox25:
--- → fixed
Whiteboard: [checkin-needed-aurora]
You need to log in
before you can comment on or make changes to this bug.
Description
•