Closed
Bug 887404
Opened 12 years ago
Closed 12 years ago
Browserglue tests should be able to run in parallel
Categories
(Firefox :: Bookmarks & History, defect)
Firefox
Bookmarks & History
Tracking
()
RESOLVED
FIXED
Firefox 25
People
(Reporter: mihneadb, Assigned: mak)
References
Details
Attachments
(1 file, 3 obsolete files)
2.64 KB,
patch
|
Details | Diff | Splinter Review |
Right now running the tests in browser/components/places/tests/unit with the patch from bug 887054 does not work, tests are failing.
Assignee | ||
Comment 1•12 years ago
|
||
taking for investigation, though if you find a solution earlier feel free to steal
Assignee: nobody → mak77
Status: NEW → ASSIGNED
Reporter | ||
Comment 2•12 years ago
|
||
The problem was the following:
test_browserGlue_distribution.js creates a distribution.ini file in the bin directory to check this functionality. The distribution.ini file *has* to live in the bin directory, and that directory is common to all processes.
This distribution.ini file is loaded by all the processes and it changes the bookmarks for all of them.
From what I looked and asked around, there is no way to disable this functionality or to have the distribution.ini file live somewhere else.
This is why I'm disabling this test (for now at least). I asked about maybe having a pref to disable this behaviour and I was told that is not desired.
Reporter | ||
Comment 3•12 years ago
|
||
Comment on attachment 769200 [details] [diff] [review]
fix
Turns out tests are still failing. Also, no need to disable browserGlue_distribution, we can just mark it run-sequentially (this is valid after the patch in bug 887054 lands.
Attachment #769200 -
Attachment is obsolete: true
Reporter | ||
Comment 4•12 years ago
|
||
There was a bug in the test harness. As said before, if test_browserGlue_distribution.js is run separately, everything runs.
That's why I used the run-sequentially option in the manifest. This is supported by the new harness.
Assignee: mak77 → mihneadb
Assignee | ||
Comment 5•12 years ago
|
||
Good catch!
The comment in the patch looks wrong, it states all of the browserglue test have a problem, not just the distribution test, could you please fix it?
What you says in comment 2 is correct, sadly there's no way to test distribution differently than by changing the application dir, though we may introduce one.
We could add an hidden pref that tells the component where to find the distribution.ini (maybe not a direct path, but like a boolean "browser.distribution.loadFromProfile", so we don't have to modify the appdir, we just copy our test file to the profile folder and set the pref.
The code loading the file is here http://mxr.mozilla.org/mozilla-central/source/browser/components/distribution.js#22 and changing the test is trivial. I can make the patch or review one, if you wish.
Assignee | ||
Comment 6•12 years ago
|
||
well, I think I will just make a patch, since it should not take a lot of time.
Reporter | ||
Comment 7•12 years ago
|
||
I asked about a pref and I was told that is not desired. If you think it s ok, go for it!
Assignee | ||
Comment 8•12 years ago
|
||
not desired for what reason? and what kind of pref?
Assignee | ||
Comment 9•12 years ago
|
||
Also, who did you ask to?
Assignee | ||
Comment 10•12 years ago
|
||
This is the patch, quite trivial.
Now I suppose the best reviewer is the same person who told you to not use a pref, since there may be reasons behind that escaping me.
The only downside I see is that we don't test anymore that the distribution file is in "XREExeF", but that has never been the purpose of this test, and this is doing more computation than the one needed to do that, so if we want to retain a test for that that will run sequentially, I'd rather write a separate test that only does that, so we keep the parallel speed gain for this test that does far more. I don't think that actually matters fwiw, but again it's trivial to do.
Reporter | ||
Comment 11•12 years ago
|
||
I don't remember, it was in #developers. I guess we can find out at review time.
Assignee | ||
Comment 12•12 years ago
|
||
Comment on attachment 771472 [details] [diff] [review]
allow browserGlue to run parallel to other tests
Review of attachment 771472 [details] [diff] [review]:
-----------------------------------------------------------------
Well, I would prefer to hit the right person, though in lack of that I will go for a more general approval from Gavin. The review should take just a few minutes.
Attachment #771472 -
Flags: review?(gavin.sharp)
Comment 13•12 years ago
|
||
Comment on attachment 771472 [details] [diff] [review]
allow browserGlue to run parallel to other tests
I think I'd prefer calling the pref "distribution.testing.loadFromProfile" to better indicate that this is intended for test purposes only (and hopefully avoid people relying on this more widely).
Attachment #771472 -
Flags: review?(gavin.sharp) → review+
Assignee | ||
Comment 14•12 years ago
|
||
change the pref name as requested.
https://hg.mozilla.org/integration/mozilla-inbound/rev/280b4d55a2a5
Assignee: mihneadb → mak77
Attachment #771070 -
Attachment is obsolete: true
Attachment #771472 -
Attachment is obsolete: true
Assignee | ||
Updated•12 years ago
|
Component: Places → Bookmarks & History
OS: Linux → All
Product: Toolkit → Firefox
Hardware: x86_64 → All
Assignee | ||
Updated•12 years ago
|
Target Milestone: --- → Firefox 25
Comment 15•12 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•