Use an eslint rule to transform existing setup tasks to use add_setup
Categories
(Testing :: Mochitest, task, P3)
Tracking
(firefox100 fixed)
| Tracking | Status | |
|---|---|---|
| firefox100 | --- | fixed |
People
(Reporter: Gijs, Assigned: Gijs)
References
(Blocks 1 open bug)
Details
Attachments
(4 files)
bug 1720335 adds add_setup. Now let's switch existing tests to it, so that .skip and .only will start working correctly in more cases, and we can experiment with having other tools like pref environments work correctly depending on the context in which they're invoked.
| Assignee | ||
Updated•4 years ago
|
Comment 1•4 years ago
|
||
The severity field is not set for this bug.
:ahal, could you have a look please?
For more information, please visit auto_nag documentation.
| Assignee | ||
Comment 2•4 years ago
|
||
Updated•4 years ago
|
| Assignee | ||
Comment 3•4 years ago
|
||
| Assignee | ||
Comment 5•4 years ago
|
||
Comment 6•4 years ago
|
||
Backed out for causing multiple dt and bc failures
Failure log 1 // Failure log 2 // Failure log 3 // Failure log 4 // Failure log 5 // Failure log 6
Updated•4 years ago
|
| Assignee | ||
Comment 7•4 years ago
|
||
Without this, changing to add_setup in individual test files causes the tasks to be reordered, which causes tests to fail.
I also had to adjust an enterprise policy test that was expecting setup tests to run inbetween tasks.
Depends on D142441
Comment 9•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/259e01cdb165
https://hg.mozilla.org/mozilla-central/rev/d0f843d504bb
https://hg.mozilla.org/mozilla-central/rev/7eb53ef3d0e4
https://hg.mozilla.org/mozilla-central/rev/6167d8a8aa15
Comment 10•4 years ago
|
||
The new rule is case-sensitive, so there's a few missed functions named setUp.
https://searchfox.org/mozilla-central/search?q=function+setUp%28%29&path=&case=true®exp=false
| Assignee | ||
Comment 11•4 years ago
|
||
(In reply to Geoff Lankow (:darktrojan) from comment #10)
The new rule is case-sensitive, so there's a few missed functions named
setUp.
https://searchfox.org/mozilla-central/search?q=function+setUp%28%29&path=&case=true®exp=false
Thanks for pointing this out, I filed bug 1762444 for this. FWIW, I mostly wrote the rule to help socialize the new concept and avoid copy-paste of existing tests meaning that it goes unused. Taken together, I'm hoping this will pave the way to better logic around e.g. making SpecialPowers.pushPrefEnv more ergonomic, and having a per-task vs per-file version. But that's still a way off.
Description
•