Fix more tests that fail when New Tab is packaged as a built-in addon
Categories
(Firefox :: New Tab Page, task, P1)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox138 | --- | fixed |
People
(Reporter: mconley, Assigned: mconley)
References
Details
(Whiteboard: [hnt-trainhop-project])
Attachments
(7 files)
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review | |
|
48 bytes,
text/x-phabricator-request
|
Details | Review |
There are a few tests outside of browser/extensions/newtab that are failing, and upon investigation of this, I have some additional changes to introduce in advance of packaging newtab as a built-in addon.
Updated•1 year ago
|
| Assignee | ||
Comment 1•1 year ago
|
||
It looks like attempting to create an nsIChannel / nsILoadInfo right at
the onset of an xpcshell test isn't a great idea and will fail intermittently
with NS_ERROR_NOT_AVAILABLE. This updates the test to create the nsIChannel
and nsILoadInfo in the add_task function instead.
| Assignee | ||
Comment 2•1 year ago
|
||
Waiting until the addon database is ready and the addonReady promise resolves
can take far, far too long, and cause regressions in our Talos tests. What
we really care about waiting for is resource-mapping.js having finished its
job to map resource://newtab and chrome://newtab URIs to the right places.
So we just have resource-mapping.js directly inform AboutNewTabRedirector
when that has occurred.
| Assignee | ||
Comment 3•1 year ago
|
||
| Assignee | ||
Comment 4•1 year ago
|
||
In order to make activity-stream.css accessible to the newtab page, we need to register
it at a chrome URI. We were originally doing this via ComponentManager.addBootstrappedManifestLocation,
which is a holdover from old bootstrapped addons. It turns out that this only works when
the path passed to it is either to an XPI or a "real" directory on the file system. When
packaging newtab as a built-in addon, when not running an out-of-band update, it's hosted
in the omni.ja JAR file, and that's not supported by addBootstrappedManifestLocation.
This patch does two things:
- It gets rid of the chrome.manifest file, and
- Has resource-mapping.js call into amIAddonManagerStartup's
registerChromeinstead.
Notably, however, contentaccessible=yes directives for chrome URIs were being ignored
except for testing environments. That was originally added in bug 1451503 when the
reftest addon was ported to a WebExtension. I've gone ahead and removed the NS_ENSURE
check for being in the automation case.
| Assignee | ||
Updated•1 year ago
|
Comment 6•1 year ago
|
||
| bugherder | ||
Comment 8•1 year ago
|
||
| bugherder | ||
| Assignee | ||
Comment 9•1 year ago
|
||
This allows the tests to have the newtab built-in addon be installed
and enabled properly when running in automation.
| Assignee | ||
Comment 10•1 year ago
|
||
| Assignee | ||
Comment 11•1 year ago
|
||
Without this preference set in the test, none of the built-in addons
(including the newtab build-in addon) will be available during the
test.
Comment 12•1 year ago
|
||
Comment 13•1 year ago
|
||
| bugherder | ||
| Assignee | ||
Comment 14•1 year ago
|
||
With bug 1949511 landed and merged, this is done.
Updated•1 year ago
|
| Assignee | ||
Comment 15•4 months ago
|
||
Mass moving from [hnt-trainhop] to [hnt-trainhop-project] for better JIRA book-keeping.
Updated•4 months ago
|
Description
•