Reorganization of Firefox-UI tests in mozilla-central
gijskruitbosch at gmail.com
Thu Sep 1 16:24:46 UTC 2016
(CC'ing firefox-dev which doesn't seem to have had the original email
though it should have done, please follow up to m.d.platform.)
On 01/09/2016 16:37, Henrik Skupin wrote:
> * locationbar tests: /browser/base/content/test/urlbar/firefox_ui/
> * private browsing tests:
> * safe browsing tests:
> * session store tests: /browser/components/sessionstore/test/firefox_ui/
> * update tests: /toolkit/mozapps/update/tests/firefox_ui/
> Do those locations sound good? I have heard at least once that
> "firefox_ui" might not be the best choice as folder name, but that's how
> the harness is called, and corresponds to what we have for other
> harnesses too.
As I did over IRC, I would like to strongly object to the continued use
of per-test-type subfolders in our test directories. You can already use
a specific mach command per test type, and the tests are listed in
different manifests, *and* there's all the different filename
conventions (browser_, test_....html, test_....xul, <whatever>.js) that
further point out what type of test you're looking at. The subfolders
add nothing useful.
Furthermore, only the toolkit case is currently meaningfully split out
into subdirs. The sessionstore test/ dir has a subdir (but also has a
bundle of tests directly in that dir), and the privatebrowsing one has
no leafs and only a subdir ("browser"). None of the others have any
subdirs at all. Getting back to the toolkit case, the subdirs are
actually confusing because only some of the subdirs have tests (as a
counterexample, "data" just has random helper files) and the root
testing dir also has .cpp files in it (I guess for gtests?).
IOW, in the general case, I think that in most of those directories
there's no precedent to do what you propose.
Finally, "firefox_ui" (as well as "ui") as a name for a directory is
going to cause all kinds of confusion for people exploring the repo
without detailed knowledge of what's going on. Additionally, it's not
like most of the mochitest-browser tests aren't tests of the Firefox
UI... If we absolutely must have some kind of subdirectory because of
reasons I have yet to hear, I think "integration" would be a better
choice of name as far as subdirs of "test" go (as juxtaposed to "unit"
for our xpcshell tests).
More information about the firefox-dev