Commit Graph

675 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
5122357c49 Bug 1736163 - layout.css.prefers-color-scheme.content-override should trigger a look and feel update.
MANUAL PUSH: Trivial orange fix CLOSED TREE
2021-10-17 15:32:02 +02:00
Rob Wu
21328a3a9e Bug 1641735 - Set useAddonManager by default on Android in mochitests r=zombie
Several mochitests currently add boilerplate useAddonManager and an
extension ID, because the implementations of some extension APIs depend
on a registration with the AddonManager via GeckoViewWebExtension.

To avoid the need for this boilerplate, use the AddonManager by default
in mochitests on Android only.
xpcshell tests can use `useAddonManager: "android-only"` to opt in to
the same mechanism.

Differential Revision: https://phabricator.services.mozilla.com/D124087
2021-09-27 13:34:54 +00:00
Mark Banner
30f1b8637e Bug 1602940 - Manual fixes to fix issues in files. r=Gijs,necko-reviewers,rpl,kershaw
Depends on D124392

Differential Revision: https://phabricator.services.mozilla.com/D124393
2021-09-06 09:53:52 +00:00
Mark Banner
11bfa90d06 Bug 1602940 - Automated replacements to use Services.uuid. r=Gijs,necko-reviewers,preferences-reviewers,kershaw
Depends on D124391

Differential Revision: https://phabricator.services.mozilla.com/D124392
2021-09-06 09:53:52 +00:00
Matt Woodrow
b8eef01e83 Bug 1708403 - Make resetting of scroll position for drawSnapshot opt-in. r=mstange,kmag
Differential Revision: https://phabricator.services.mozilla.com/D117613
2021-08-25 20:49:18 +00:00
Emilio Cobos Álvarez
de54c4e1fc Bug 1718755 - Fix the SpecialPowers pref code to deal with ui / font prefs correctly after the previous change. r=kmag
This allows us to remove the timeout (which was there for these prefs)
and makes the code a bit more explicit.

Unconditionally making all tests wait for rAF causes some timing changes
which cause some tests to time out / fail, see:

  https://treeherder.mozilla.org/jobs?repo=try&revision=3aef4c168c6ab7d762dd360f49d4f56dff686c03

So this only does it when changing the prefs that care about it. Fix
some tests that were relying on the timeout to get this green.

Differential Revision: https://phabricator.services.mozilla.com/D119040
2021-07-20 14:10:58 +00:00
Butkovits Atila
433d514141 Backed out 4 changesets (bug 1718755) for causing Reftest failures. CLOSED TREE
Backed out changeset f2cc4fb3caa8 (bug 1718755)
Backed out changeset babc4fdcd08c (bug 1718755)
Backed out changeset 4566477a7075 (bug 1718755)
Backed out changeset 3cc5fcf9aeb6 (bug 1718755)
2021-07-14 18:36:32 +03:00
Emilio Cobos Álvarez
0d448eff03 Bug 1718755 - Fix the SpecialPowers pref code to deal with ui / font prefs correctly after the previous change. r=kmag
This allows us to remove the timeout (which was there for these prefs)
and makes the code a bit more explicit.

Unconditionally making all tests wait for rAF causes some timing changes
which cause some tests to time out / fail, see:

  https://treeherder.mozilla.org/jobs?repo=try&revision=3aef4c168c6ab7d762dd360f49d4f56dff686c03

So this only does it when changing the prefs that care about it. Fix
some tests that were relying on the timeout to get this green.

Differential Revision: https://phabricator.services.mozilla.com/D119040
2021-07-14 11:29:25 +00:00
Masayuki Nakano
a81636618b Bug 1719387 - Make test_bug795418-2.html request text/unicode flavor in the headless mode r=smaug
Until fixing bug 1686012, clipboard in the headless mode does not support
"text/html" flavor.  Therefore, the `waitForClipboard` in the test does not
get expected value as `aData` in the first callback.

So, it should request `text/unicode` in the headless mode.

Depends on D119483

Differential Revision: https://phabricator.services.mozilla.com/D119484
2021-07-12 03:55:21 +00:00
Sandor Molnar
320d01b1d8 Backed out 2 changesets (bug 1718755) for causing build bustages. CLOSED TREE DONTBUILD
Backed out changeset eae7bcfd58c9 (bug 1718755)
Backed out changeset 6ad9e60bc38e (bug 1718755)
2021-07-08 12:55:09 +03:00
Emilio Cobos Álvarez
2cdef2f45e Bug 1718755 - Fix the SpecialPowers pref code to deal with ui / font prefs correctly after the previous change. r=kmag
This allows us to remove the timeout (which was there for these prefs)
and makes the code a bit more explicit.

Unconditionally making all tests wait for rAF causes some timing changes
which cause some tests to time out / fail, see:

  https://treeherder.mozilla.org/jobs?repo=try&revision=3aef4c168c6ab7d762dd360f49d4f56dff686c03

So this only does it when changing the prefs that care about it. Fix
some tests that were relying on the timeout to get this green.

Differential Revision: https://phabricator.services.mozilla.com/D119040
2021-07-08 09:23:36 +00:00
Yaron Tausky
768366d7b8 Bug 1496997 - Remove dom.serviceWorkers.parent_intercept pref r=asuth,dom-workers-and-storage-reviewers,perftest-reviewers,jgraham,sparky,webdriver-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D101788
2021-06-15 08:52:39 +00:00
Dana Keeler
ef0a88c6f2 Bug 1715142 - introduce nsIPublicKeyPinningService and remove 'type' parameter from nsISiteSecurityService r=rmf,necko-reviewers
The public key pinning implementation is much less complex than the HSTS
implementation, and only needs a small subset of the parameters of the latter.
Furthermore, the information it relies on is static, and so is safe to access
from content processes. This patch separates the two implementations, thus
simplifying both of them and avoiding some unnecessary IPC calls in the
process.

Differential Revision: https://phabricator.services.mozilla.com/D117096
2021-06-12 01:12:25 +00:00
Butkovits Atila
e4394b27a2 Backed out 3 changesets (bug 1715142) for causing build bustages. CLOSED TREE
Backed out changeset 7e67994f6a65 (bug 1715142)
Backed out changeset f58d5156f332 (bug 1715142)
Backed out changeset f8a7bd4519c6 (bug 1715142)
2021-06-11 21:20:02 +03:00
Dana Keeler
f84faf1bf5 Bug 1715142 - introduce nsIPublicKeyPinningService and remove 'type' parameter from nsISiteSecurityService r=rmf,necko-reviewers
The public key pinning implementation is much less complex than the HSTS
implementation, and only needs a small subset of the parameters of the latter.
Furthermore, the information it relies on is static, and so is safe to access
from content processes. This patch separates the two implementations, thus
simplifying both of them and avoiding some unnecessary IPC calls in the
process.

Differential Revision: https://phabricator.services.mozilla.com/D117096
2021-06-11 17:58:19 +00:00
Iulian Moraru
955a3ab572 Backed out 2 changesets (bug 1715142) for causing marionette failures on test_navigation.py and mochitest failures on browser_setIgnoreCertificateErrors.js. CLOSED TREE
Backed out changeset 83206685ca0b (bug 1715142)
Backed out changeset ab3060a5f69e (bug 1715142)
2021-06-11 02:45:34 +03:00
Dana Keeler
f3c620e4c3 Bug 1715142 - introduce nsIPublicKeyPinningService and remove 'type' parameter from nsISiteSecurityService r=rmf,necko-reviewers
The public key pinning implementation is much less complex than the HSTS
implementation, and only needs a small subset of the parameters of the latter.
Furthermore, the information it relies on is static, and so is safe to access
from content processes. This patch separates the two implementations, thus
simplifying both of them and avoiding some unnecessary IPC calls in the
process.

Differential Revision: https://phabricator.services.mozilla.com/D117096
2021-06-10 22:13:32 +00:00
Geoff Brown
25c09b3ab0 Bug 1713208 - Use lazy module getter for AppUiTestDelegate; r=agi
Use lazy module getter to avoid import failures during jsreftests, which
flood test logs with warning messages.

Differential Revision: https://phabricator.services.mozilla.com/D116298
2021-06-04 17:47:20 +00:00
Neil Deakin
a31f833dd2 Bug 1712900, rework waitForFocus/promiseFocus so that it works with fission, r=hsivonen
Instead of using a framescript, change promiseFocus to use the SpecialPowers actor. In addition, promiseFocus may now take a browsing context to focus a specific subframe's window. If that subframe is deeply nested, messages will be passed back and forth between the parent and each successive subframe to get to the one subframe that is desired to be focused. Similarly, this process is used when focusing a higher level frame that already has its focused element set to a subframe.

Differential Revision: https://phabricator.services.mozilla.com/D116387
2021-06-03 19:41:19 +00:00
David Parks
e3ee50c76a Bug 1676542 : Remove NPAPI plugin-related code from reftest harness r=jmaher,tnikkel
NPAPI plugins are no longer supported.  MozPaintWait and MozPaintWaitFinished events are no longer sent -- they came exclusively from nsPluginInstanceOwner, which was removed in bug 1682030.

Differential Revision: https://phabricator.services.mozilla.com/D114021
2021-05-01 01:47:48 +00:00
David Parks
2b32f597cb Bug 1682030 - Remove NPAPI from tests outside of dom/plugins. r=Gijs,cmartin
Removes NPAPI plugin features from tests outside of dom/plugins.  Some tests are updated to avoid NPAPI behavior and others are deleted if they no longer offer anthing useful.

Differential Revision: https://phabricator.services.mozilla.com/D107134
2021-04-06 19:28:09 +00:00
Csoregi Natalia
d68661e2cc Backed out 24 changesets (bug 1682030) for bustage on ProcessHangMonitor.cpp and nsCOMPtr.h. CLOSED TREE
Backed out changeset 5b1644096477 (bug 1682030)
Backed out changeset 35ae60eea3c7 (bug 1682030)
Backed out changeset 3eca76a6d639 (bug 1682030)
Backed out changeset 259c45447ad9 (bug 1682030)
Backed out changeset de9222dc8c31 (bug 1682030)
Backed out changeset 2986c7e14349 (bug 1682030)
Backed out changeset 6af3410bdb93 (bug 1682030)
Backed out changeset 42b0621c2927 (bug 1682030)
Backed out changeset 366e3e371858 (bug 1682030)
Backed out changeset 9adb2865adea (bug 1682030)
Backed out changeset 6af6af3bc03a (bug 1682030)
Backed out changeset da94a91b35ae (bug 1682030)
Backed out changeset 9143da258d0e (bug 1682030)
Backed out changeset 5e20d06952ba (bug 1682030)
Backed out changeset 6253d7e1ce7d (bug 1682030)
Backed out changeset 0e06ddeea3e2 (bug 1682030)
Backed out changeset 9c58d57c9e44 (bug 1682030)
Backed out changeset e90edd89430e (bug 1682030)
Backed out changeset 5861b8166b10 (bug 1682030)
Backed out changeset b4b88cdc7993 (bug 1682030)
Backed out changeset b80054e9805c (bug 1682030)
Backed out changeset 580d857674c0 (bug 1682030)
Backed out changeset a9cdf93c2662 (bug 1682030)
Backed out changeset 9c9c8b4998e2 (bug 1682030)
2021-04-06 03:54:12 +03:00
David Parks
3f9712f20f Bug 1682030 - Remove NPAPI from tests outside of dom/plugins. r=Gijs,cmartin
Removes NPAPI plugin features from tests outside of dom/plugins.  Some tests are updated to avoid NPAPI behavior and others are deleted if they no longer offer anthing useful.

Differential Revision: https://phabricator.services.mozilla.com/D107134
2021-04-05 23:48:32 +00:00
Luca Greco
7b459bbed3 Bug 1698158 - part 3.2 - Remove unnecessary imports from testharness addons experimental API. r=mixedpuppy
Differential Revision: https://phabricator.services.mozilla.com/D108229
2021-03-16 18:15:41 +00:00
Florian Quèze
06bedf6439 Bug 1697797 - Add profiler markers on BrowserTestUtils, TestUtils and SpecialPowers methods, r=mconley.
Differential Revision: https://phabricator.services.mozilla.com/D108009
2021-03-11 21:39:50 +00:00
Kris Maglione
b07bf8b037 Bug 1691595: Move evictAllContentViewers test code to SpecialPowers. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D104477
2021-02-18 21:04:12 +00:00
Kris Maglione
0ec4615244 Bug 1662840: Move overrideDPPX from nsIContentViewer to BrowsingContext. r=whimboo,remote-protocol-reviewers,mtigley,emilio
Differential Revision: https://phabricator.services.mozilla.com/D104001
2021-02-10 01:30:35 +00:00
Mirko Brodesser
b93e8fa930 Bug 1691666: part 2) Add some documentation to SpecialPowersChild.doCommand. r=masayuki
Depends on D104504

Differential Revision: https://phabricator.services.mozilla.com/D104505
2021-02-09 15:16:15 +00:00
Mirko Brodesser
f6e09159b2 Bug 1691666: part 1) Add some documentation to SpecialPowersChild.setCommandNode. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D104504
2021-02-09 15:16:15 +00:00
Agi Sferro
41c023ef42 Bug 1681360 - Add mochitest ApiTestDelegate. r=robwu,esawin
This change adds a new mochitest-only helper called `AppTestDelegate`. This
helper will provide primitives that are not normally available at the toolkit
level.

Each app can implement the `AppUiTestDelegate` API to provide the primitives.
This is done so that we can ensure compatibility of the Extension API across
implementations.

The initial set of APIs is as follows:

```
class TestDelegate {
    clickPageAction(window, extensionId);
    closePageAction(window, extensionId);
    clickBrowserAction(window, extensionId);
    closeBrowserAction(window, extensionId);
    awaitExtensionPanel(window, extensionId);
    // Returns a unique identifier for the tab
    openNewForegroundTab(window, url, waitForLoad);
    // tabId must be the identifier from openNewForegroundTab
    removeTab(tabId);
}
```

Differential Revision: https://phabricator.services.mozilla.com/D99170
2021-02-04 02:19:05 +00:00
Emilio Cobos Álvarez
bfe77f303a Bug 1591120 - Move print and color-scheme simulation to browsingContext. r=ochameau,nika,devtools-backward-compat-reviewers
We keep mMedium in nsPresContext rather than just looking it up in the
browsing context because that's used quite more frequently.

Differential Revision: https://phabricator.services.mozilla.com/D103782
2021-02-03 10:38:09 +00:00
Dorel Luca
85e20aac7c Backed out 3 changesets (bug 1681360) for Browser-chrome failures in browser/base/content/test/performance/browser_startup_content_subframe.js. CLOSED TREE
Backed out changeset 2e07885dda4c (bug 1681360)
Backed out changeset c80806107851 (bug 1681360)
Backed out changeset 49e0948090b9 (bug 1681360)
2021-01-30 01:12:33 +02:00
Agi Sferro
aa0dacc820 Bug 1681360 - Add mochitest ApiTestDelegate. r=robwu,esawin
This change adds a new mochitest-only helper called `AppTestDelegate`. This
helper will provide primitives that are not normally available at the toolkit
level.

Each app can implement the `AppUiTestDelegate` API to provide the primitives.
This is done so that we can ensure compatibility of the Extension API across
implementations.

The initial set of APIs is as follows:

```
class TestDelegate {
    clickPageAction(window, extensionId);
    closePageAction(window, extensionId);
    clickBrowserAction(window, extensionId);
    closeBrowserAction(window, extensionId);
    awaitExtensionPanel(window, extensionId);
    // Returns a unique identifier for the tab
    openNewForegroundTab(window, url, waitForLoad);
    // tabId must be the identifier from openNewForegroundTab
    removeTab(tabId);
}
```

Differential Revision: https://phabricator.services.mozilla.com/D99170
2021-01-29 19:01:20 +00:00
Florian Quèze
70b524ecf0 Bug 1687784 - Profiler markers from mochitests and xpcshell tests should use the Test category, r=mconley.
Differential Revision: https://phabricator.services.mozilla.com/D102466
2021-01-20 21:04:00 +00:00
Kartikaya Gupta
88b1045f59 Bug 1686130 - Fix delay argument propagation. r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D101425
2021-01-12 19:41:51 +00:00
pbz
4cf818dd4f Bug 1338637 - Added test for folder upload confirmation prompt. r=Gijs
This also fixes an issue where MockFilePicker wouldn't set the mode correctly,
which caused it to always use "modeOpen". For this test we need to pass
"modeGetFolder" in order for the prompt to show.

Differential Revision: https://phabricator.services.mozilla.com/D96526
2020-11-17 17:14:49 +00:00
Razvan Maries
d92ef717a6 Backed out 2 changesets (bug 1338637) for perma failures on test_webkitdirectory.html. CLOSED TREE
Backed out changeset 5bddcb99f650 (bug 1338637)
Backed out changeset 5c29fd30af97 (bug 1338637)
2020-11-16 18:49:34 +02:00
pbz
8587608ed8 Bug 1338637 - Added test for folder upload confirmation prompt. r=Gijs
This also fixes an issue where MockFilePicker wouldn't set the mode correctly,
which caused it to always use "modeOpen". For this test we need to pass
"modeGetFolder" in order for the prompt to show.

Differential Revision: https://phabricator.services.mozilla.com/D96526
2020-11-16 09:33:25 +00:00
Ricky Stewart
02a7b4ebdf Bug 1654103: Standardize on Black for Python code in mozilla-central.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara
da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart
c0cea3b0fa Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Dorel Luca
1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart
50762dacab Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Andrew Swan
6b380a56a7 Bug 1396399: Test for content scripts and activeTab permission.
Differential Revision: https://phabricator.services.mozilla.com/D90333
2020-09-22 17:41:36 +00:00
Kris Maglione
890adab104 Bug 1658791: Make SpecialPowers.pushPermissions Fission-compatible. r=mccr8
Some tests rely on SpecialPowers.pushPermissions/popPermissions/flushPermissions
operating on the same permissions stack no matter the SpecialPowers instance
they're called on. This works when all of those SpeicalPowers instances are in
the same process, but with out-of-process Fision frames, that isn't always the
case.

This patch updates the permission stack code to operate the same way as the
preference stack code, which was already updated to deal with this issue.

Differential Revision: https://phabricator.services.mozilla.com/D90320
2020-09-16 19:32:46 +00:00
Mirko Brodesser
cd62133ad8 Bug 1659963: document SpecialPowers.removePermission. r=kmag
Helps understanding it.

Differential Revision: https://phabricator.services.mozilla.com/D90261
2020-09-16 08:16:36 +00:00
Razvan Maries
f4133af85c Backed out changeset 09f6522b2f48 (bug 1396399) for perma failures on test_ext_contentscript_activeTab.html. CLOSED TREE 2020-09-16 08:36:43 +03:00
Andrew Swan
d6d39c34ba Bug 1396399: Test for content scripts and activeTab permission.
Differential Revision: https://phabricator.services.mozilla.com/D90333
2020-09-16 02:04:08 +00:00
Brindusan Cristian
5cb053c42a Backed out changeset 309b64bd96a1 (bug 1396399) for mochitest failures at test_ext_contentscript_activeTab.html and ESlint failure at SpecialPowersParent.jsm. CLOSED TREE 2020-09-16 03:33:38 +03:00
Andrew Swan
f56339c2d3 Bug 1396399: Test for content scripts and activeTab permission.
Differential Revision: https://phabricator.services.mozilla.com/D90333
2020-09-15 23:54:24 +00:00