Граф коммитов

256 Коммитов

Автор SHA1 Сообщение Дата
Alexandre Poirot ded026f627 Bug 1700106 - [devtools] Remove now-useless eslint files related to mochitests. r=jdescottes,Standard8
I kept a few having some overrides. But they may be irrelevant.
And I kept some eslint files for all folder that aren't matching the pattern matching "**/test*/**/browser*/".
Ideally we would rename these folder to match.

Last but not least, I identified one case where we were using mochitest file for xpcshell tests!

Differential Revision: https://phabricator.services.mozilla.com/D109481
2021-03-23 15:51:18 +00:00
Julian Descottes d9b1d58f33 Bug 1694140 - [devtools] Stop using TargetFactory forTab in devtools browser mochitests r=nchevobbe
Depends on D105999

This patch is mostly a mechanical rewrite of:
```lang=javascript
const target = await TargetFactory.forTab(tab);
const toolbox = await gDevTools.showToolbox(target, "inspector");
```
to
```lang=javascript
const toolbox = await gDevTools.showToolboxForTab(tab, { toolId: "inspector" });
```

The main changes are:
- if the target was actually used in the test, it is now retrieved from toolbox.target
- the arguments for showToolboxForTab are using an option argument, to avoid the occasional showToolbox("inspector", null, null, null, startTime, null, reason);

I suspect that any signature rewrite mistake would have been caught on try.
There a few less mechanical changes:
- devtools/client/framework/test/browser_toolbox_screenshot_tool.js the toolId "console" was omitted because this id doesn't match any tool (author probably meant "webconsole")
- a few tests were: 1/ first creating a target, 2/ looping on tool definitions to get supported tools 3/ opening the toolbox with each supported tool. To support this I extracted a helper called `getSupportedToolIds` which opens a temporary toolbox to list all supported tool ids
- all the tests under storage/ use a single helper to start the test, which can open toolboxes for both tab targets and other targets. This made it more complicated to refactor. We could also drop this part and just refactor each test when we actually modify forTab/showToolbox to only work with descriptors

All in all the goal of this stack is to pave the way to stop handling targets when using forTab/showToolbox, and behind the scenes stop replying on targets to cache open toolboxes. We don't aim to kill all the call sites, just get them to a smaller number so that the next refactors will be easier.

Differential Revision: https://phabricator.services.mozilla.com/D106000
2021-02-25 18:02:52 +00:00
Brindusan Cristian 39abcde940 Backed out 10 changesets (bug 1694140, bug 1694886, bug 1688688) for devtools failures on browser_CORS-console-warnings.js. CLOSED TREE
Backed out changeset 1b7367a27d9a (bug 1694886)
Backed out changeset d5a70a3143ad (bug 1694140)
Backed out changeset 74adaced5c0a (bug 1694140)
Backed out changeset 0b8f857e3f90 (bug 1694140)
Backed out changeset 45a8dc952aba (bug 1694140)
Backed out changeset 299f17e9cb6f (bug 1694140)
Backed out changeset 6beb9dd48ef3 (bug 1694140)
Backed out changeset 5f6688e8fe4c (bug 1694140)
Backed out changeset ae1fa0484c91 (bug 1688688)
Backed out changeset 8a0f5c24ed9a (bug 1688688)
2021-02-25 16:07:39 +02:00
Julian Descottes 982c525960 Bug 1694140 - [devtools] Stop using TargetFactory forTab in devtools browser mochitests r=nchevobbe
Depends on D105999

This patch is mostly a mechanical rewrite of:
```lang=javascript
const target = await TargetFactory.forTab(tab);
const toolbox = await gDevTools.showToolbox(target, "inspector");
```
to
```lang=javascript
const toolbox = await gDevTools.showToolboxForTab(tab, { toolId: "inspector" });
```

The main changes are:
- if the target was actually used in the test, it is now retrieved from toolbox.target
- the arguments for showToolboxForTab are using an option argument, to avoid the occasional showToolbox("inspector", null, null, null, startTime, null, reason);

I suspect that any signature rewrite mistake would have been caught on try.
There a few less mechanical changes:
- devtools/client/framework/test/browser_toolbox_screenshot_tool.js the toolId "console" was omitted because this id doesn't match any tool (author probably meant "webconsole")
- a few tests were: 1/ first creating a target, 2/ looping on tool definitions to get supported tools 3/ opening the toolbox with each supported tool. To support this I extracted a helper called `getSupportedToolIds` which opens a temporary toolbox to list all supported tool ids
- all the tests under storage/ use a single helper to start the test, which can open toolboxes for both tab targets and other targets. This made it more complicated to refactor. We could also drop this part and just refactor each test when we actually modify forTab/showToolbox to only work with descriptors

All in all the goal of this stack is to pave the way to stop handling targets when using forTab/showToolbox, and behind the scenes stop replying on targets to cache open toolboxes. We don't aim to kill all the call sites, just get them to a smaller number so that the next refactors will be easier.

Differential Revision: https://phabricator.services.mozilla.com/D106000
2021-02-25 12:58:14 +00:00
Tim Nguyen 1cc2986424 Bug 1691314 - Use DOM hidden property instead of attribute methods in devtools/client. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D104339
2021-02-09 17:32:07 +00:00
Tim Nguyen d807516fc0 Bug 1273941 - Followup: remove leftover comment in browser_styleeditor_sourcemap_watching.js. DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D101510
2021-01-12 22:59:49 +00:00
Kartik Gautam 7ae6aea145 Bug 1684173 - Add newline character at end of files when missing r=sylvestre,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D100484
2021-01-07 08:53:08 +00:00
Cosmin Sabou 2978aa00a3 Backed out changeset dbed1cdf588f (bug 1684173) for mochitest plain and devtools failures. a=backout DONTBUILD 2020-12-28 00:43:51 +02:00
Kartik Gautam 775cdec032 Bug 1684173 - Add newline character at end of files when missing r=sylvestre
Depends on D100443

Differential Revision: https://phabricator.services.mozilla.com/D100484
2020-12-27 11:43:41 +00:00
Kartik Gautam f7ffcd09fb Bug 1679758 - Remove trailing empty lines r=sylvestre,marionette-reviewers,jgraham
Differential Revision: https://phabricator.services.mozilla.com/D99595
2020-12-15 10:34:54 +00:00
Dorel Luca 7320ae982a Backed out changeset f3aaf04fce3b (bug 1679758) for Devtool failures in browser_styleeditor_syncAddProperty.js. CLOSED TREE 2020-12-13 16:38:21 +02:00
Kartik Gautam caf549c200 Bug 1679758 - Remove trailing empty lines r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D99595
2020-12-13 13:28:30 +00:00
Daisuke Akatsuka 473676fda0 Bug 1664941: Connect style actor and stylesheet watcher. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D90651
2020-10-29 06:26:20 +00:00
Alexandre Poirot fad9e1690b Bug 1663649 - [devtools] Enable target switching by default. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D91020
2020-09-23 17:50:20 +00:00
Daisuke Akatsuka 3908e7a6d9 Bug 1644193: Implement basic server-side stylesheets watcher. r=ochameau
Depends on D88531

Differential Revision: https://phabricator.services.mozilla.com/D88540
2020-09-14 21:29:47 +00:00
Daisuke Akatsuka a936229ca0 Bug 1659589: Get property-change event via resource watcher. r=ochameau
Depends on D87041

Differential Revision: https://phabricator.services.mozilla.com/D87042
2020-08-26 08:37:18 +00:00
Daisuke Akatsuka b74df1cade Bug 1659589: Get style-applied event via resource watcher. r=ochameau,bomsy
Depends on D87040

Differential Revision: https://phabricator.services.mozilla.com/D87041
2020-08-27 22:31:52 +00:00
Brad Werth 627581e215 Bug 1621655: Make browser_styleeditor_media_sidebar_links.js test await RDM content reflow. r=rcaliman
Differential Revision: https://phabricator.services.mozilla.com/D85793
2020-08-04 15:08:19 +00:00
Daisuke Akatsuka 68aa4aa0fa Bug 1478688: Revert browser_styleeditor_fetch-from-netmonitor test. r=ochameau
Depends on D85370

Differential Revision: https://phabricator.services.mozilla.com/D85371
2020-07-31 01:33:44 +00:00
Sebastian Hengst 88a75bda99 Bug 1576459 - Set browser_styleeditor_bug_740541_iframes.js as passing with fission. r=gl DONTBUILD
Permanent passes got tracked in bug 1652659.

Differential Revision: https://phabricator.services.mozilla.com/D83622
2020-07-15 14:18:57 +00:00
Daisuke Akatsuka 6e9455cf79 Bug 1478688: Remove test codes that does not use anymore. r=Honza
Depends on D83288

Differential Revision: https://phabricator.services.mozilla.com/D83289
2020-07-13 10:38:55 +00:00
Daisuke Akatsuka 90dd432408 Bug 1478688: Avoid getting cached content from console actor. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D83287
2020-07-13 10:05:40 +00:00
Daisuke Akatsuka d1f58c00a9 Bug 1625930: Apply ResourceWatcher to StyleEditor. r=ochameau
Depends on D78239

Differential Revision: https://phabricator.services.mozilla.com/D78240
2020-07-09 04:37:54 +00:00
Dorel Luca 3e4da6b273 Backed out changeset 00e12ae2d596 (bug 1649910) for Browser-chrome failures in browser/browser_ext_devtools_inspectedWindow_targetSwitch.js. CLOSED TREE 2020-07-09 03:58:43 +03:00
Alexandre Poirot 6c430374e4 Bug 1649910 - Emit "switched-target" only after we fully attached to the new target. r=jdescottes
The previous code, emitting the event from Toolbox.onTargetAvailable,
wasn't waiting for the call to TargetList.startListening which is done
from TargetList.onTargetAvailable.

Differential Revision: https://phabricator.services.mozilla.com/D82664
2020-07-08 22:57:36 +00:00
Bogdan Tara 75881e8400 Backed out 6 changesets (bug 1625930) for test_eventemitter_basic.js failures CLOSED TREE
Backed out changeset 30a3da9f613c (bug 1625930)
Backed out changeset d4e4c3ddcc43 (bug 1625930)
Backed out changeset 0133d9c58323 (bug 1625930)
Backed out changeset 1c9cf53f2a89 (bug 1625930)
Backed out changeset f63839eff636 (bug 1625930)
Backed out changeset a6bef105a2c2 (bug 1625930)
2020-07-08 18:08:27 +03:00
Daisuke Akatsuka 899ed9d38e Bug 1625930: Apply ResourceWatcher to StyleEditor. r=ochameau
Depends on D78239

Differential Revision: https://phabricator.services.mozilla.com/D78240
2020-07-08 14:05:42 +00:00
Daisuke Akatsuka de90f65570 Bug 1646974: Add a test for the stylesheet which is loaded as internal. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D80807
2020-06-26 09:21:58 +00:00
Logan Smyth 56fa0fd410 Bug 1642371 - Part 4: Open style editor using exact front object where possible. r=jlast
Differential Revision: https://phabricator.services.mozilla.com/D77740
2020-06-03 22:38:11 +00:00
Razvan Caliman 17fd76e771 Bug 1628044 - Remove obsolete initCssProperties() helper and cleanup tests; r=jdescottes
Depends on D70071

After changes in D70071, the `CSSProperties` object is retrieved from the `CSSPropertiesFront`. The `initCssProperties()` method is no longer required. It is only used in tests.

This patch removes the leftover callsites for `initCssProperties()` from tests and the method implementation itself.

Differential Revision: https://phabricator.services.mozilla.com/D71560
2020-04-21 13:49:11 +00:00
Micah Tigley 73d553cf00 Bug 1621655 - Re-enable browser_styleeditor_media_sidebar_links.js on debug/asan builds r=bradwerth
D68234 modified the browser_styleeditor_media_sidebar_links.js test file to make sure new-RDM is opened before waiting on the content to resize. This also fixed the frequent intermittent failures for asan/debug builds on Linux.

Differential Revision: https://phabricator.services.mozilla.com/D68462

--HG--
extra : moz-landing-system : lando
2020-03-26 21:51:37 +00:00
Micah Tigley 64943317ef Bug 1624889 - Ensure RDM sets the viewport width and height when opened from the Style Editor r=bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D68234

--HG--
extra : moz-landing-system : lando
2020-03-25 21:14:56 +00:00
Razvan Maries a792e870dc Bug 1621655 - Disabled browser_styleeditor_media_sidebar_links.js on debug/asan for frequent failures. r=jmaher
Differential Revision: https://phabricator.services.mozilla.com/D67730

--HG--
extra : moz-landing-system : lando
2020-03-22 11:04:32 +00:00
Julian Descottes cfab47ff53 Bug 1604539 - Rename shared/fronts to client/fronts in the devtools codebase r=nchevobbe
Depends on D67603
This patch is an automated string replace of shared/fronts/ to client/fronts/ in devtools.

Differential Revision: https://phabricator.services.mozilla.com/D67604

--HG--
extra : moz-landing-system : lando
2020-03-20 13:58:56 +00:00
Bogdan Tara b03ab7d69b Backed out 5 changesets (bug 1604539) for xpc failures complanining about test_encryption.js CLOSED TREE
Backed out changeset 8455e50002a9 (bug 1604539)
Backed out changeset fb410a1bf9aa (bug 1604539)
Backed out changeset da94f7d503a1 (bug 1604539)
Backed out changeset b4b54335ee2d (bug 1604539)
Backed out changeset 866d6794bbba (bug 1604539)

--HG--
rename : devtools/client/fronts/accessibility.js => devtools/shared/fronts/accessibility.js
rename : devtools/client/fronts/addon/addons.js => devtools/shared/fronts/addon/addons.js
rename : devtools/client/fronts/addon/moz.build => devtools/shared/fronts/addon/moz.build
rename : devtools/client/fronts/addon/webextension-inspected-window.js => devtools/shared/fronts/addon/webextension-inspected-window.js
rename : devtools/client/fronts/animation.js => devtools/shared/fronts/animation.js
rename : devtools/client/fronts/array-buffer.js => devtools/shared/fronts/array-buffer.js
rename : devtools/client/fronts/changes.js => devtools/shared/fronts/changes.js
rename : devtools/client/fronts/content-viewer.js => devtools/shared/fronts/content-viewer.js
rename : devtools/client/fronts/css-properties.js => devtools/shared/fronts/css-properties.js
rename : devtools/client/fronts/descriptors/frame.js => devtools/shared/fronts/descriptors/frame.js
rename : devtools/client/fronts/descriptors/moz.build => devtools/shared/fronts/descriptors/moz.build
rename : devtools/client/fronts/descriptors/process.js => devtools/shared/fronts/descriptors/process.js
rename : devtools/client/fronts/descriptors/tab.js => devtools/shared/fronts/descriptors/tab.js
rename : devtools/client/fronts/descriptors/webextension.js => devtools/shared/fronts/descriptors/webextension.js
rename : devtools/client/fronts/device.js => devtools/shared/fronts/device.js
rename : devtools/client/fronts/environment.js => devtools/shared/fronts/environment.js
rename : devtools/client/fronts/frame.js => devtools/shared/fronts/frame.js
rename : devtools/client/fronts/framerate.js => devtools/shared/fronts/framerate.js
rename : devtools/client/fronts/highlighters.js => devtools/shared/fronts/highlighters.js
rename : devtools/client/fronts/inspector.js => devtools/shared/fronts/inspector.js
rename : devtools/client/fronts/inspector/moz.build => devtools/shared/fronts/inspector/moz.build
rename : devtools/client/fronts/inspector/rule-rewriter.js => devtools/shared/fronts/inspector/rule-rewriter.js
rename : devtools/client/fronts/layout.js => devtools/shared/fronts/layout.js
rename : devtools/client/fronts/manifest.js => devtools/shared/fronts/manifest.js
rename : devtools/client/fronts/memory.js => devtools/shared/fronts/memory.js
rename : devtools/client/fronts/moz.build => devtools/shared/fronts/moz.build
rename : devtools/client/fronts/node.js => devtools/shared/fronts/node.js
rename : devtools/client/fronts/object.js => devtools/shared/fronts/object.js
rename : devtools/client/fronts/perf.js => devtools/shared/fronts/perf.js
rename : devtools/client/fronts/performance-recording.js => devtools/shared/fronts/performance-recording.js
rename : devtools/client/fronts/performance.js => devtools/shared/fronts/performance.js
rename : devtools/client/fronts/preference.js => devtools/shared/fronts/preference.js
rename : devtools/client/fronts/property-iterator.js => devtools/shared/fronts/property-iterator.js
rename : devtools/client/fronts/reflow.js => devtools/shared/fronts/reflow.js
rename : devtools/client/fronts/responsive.js => devtools/shared/fronts/responsive.js
rename : devtools/client/fronts/root.js => devtools/shared/fronts/root.js
rename : devtools/client/fronts/screenshot.js => devtools/shared/fronts/screenshot.js
rename : devtools/client/fronts/source.js => devtools/shared/fronts/source.js
rename : devtools/client/fronts/storage.js => devtools/shared/fronts/storage.js
rename : devtools/client/fronts/string.js => devtools/shared/fronts/string.js
rename : devtools/client/fronts/styles.js => devtools/shared/fronts/styles.js
rename : devtools/client/fronts/stylesheets.js => devtools/shared/fronts/stylesheets.js
rename : devtools/client/fronts/symbol-iterator.js => devtools/shared/fronts/symbol-iterator.js
rename : devtools/client/fronts/targets/browsing-context.js => devtools/shared/fronts/targets/browsing-context.js
rename : devtools/client/fronts/targets/content-process.js => devtools/shared/fronts/targets/content-process.js
rename : devtools/client/fronts/targets/local-tab.js => devtools/shared/fronts/targets/local-tab.js
rename : devtools/client/fronts/targets/moz.build => devtools/shared/fronts/targets/moz.build
rename : devtools/client/fronts/targets/target-mixin.js => devtools/shared/fronts/targets/target-mixin.js
rename : devtools/client/fronts/targets/worker.js => devtools/shared/fronts/targets/worker.js
rename : devtools/client/fronts/thread.js => devtools/shared/fronts/thread.js
rename : devtools/client/fronts/walker.js => devtools/shared/fronts/walker.js
rename : devtools/client/fronts/webconsole.js => devtools/shared/fronts/webconsole.js
rename : devtools/client/fronts/websocket.js => devtools/shared/fronts/websocket.js
rename : devtools/client/fronts/worker/moz.build => devtools/shared/fronts/worker/moz.build
rename : devtools/client/fronts/worker/push-subscription.js => devtools/shared/fronts/worker/push-subscription.js
rename : devtools/client/fronts/worker/service-worker-registration.js => devtools/shared/fronts/worker/service-worker-registration.js
rename : devtools/client/fronts/worker/service-worker.js => devtools/shared/fronts/worker/service-worker.js
2020-03-20 15:53:23 +02:00
Julian Descottes ad4b5dfb37 Bug 1604539 - Rename shared/fronts to client/fronts in the devtools codebase r=nchevobbe
Depends on D67603
This patch is an automated string replace of shared/fronts/ to client/fronts/ in devtools.

Differential Revision: https://phabricator.services.mozilla.com/D67604

--HG--
extra : moz-landing-system : lando
2020-03-20 12:57:58 +00:00
Julian Descottes 0cf76f06a1 Bug 1620194 - Remove test-actor-registry and expose simplified helpers in shared-head.js r=ochameau
Depends on D65570

Differential Revision: https://phabricator.services.mozilla.com/D65575

--HG--
extra : moz-landing-system : lando
2020-03-18 09:29:58 +00:00
Andreea Pavel c63a7a8d35 Bug 1424914 - adjust disabling condition on a CLOSED TREE r=test-only 2020-03-13 21:26:25 +02:00
Andreea Pavel cb7f5adb3b Bug 1424914 - Disable browser_styleeditor_bug_1405342_serviceworker_iframes.js on Win and Linux64 r=egao
Differential Revision: https://phabricator.services.mozilla.com/D66419

--HG--
extra : moz-landing-system : lando
2020-03-12 17:16:19 +00:00
Micah Tigley aa2e990453 Bug 1621306 - Enable the devtools.responsive.browserUI.enabled pref in Nightly only r=bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D66246

--HG--
extra : moz-landing-system : lando
2020-03-11 11:41:48 +00:00
Dorel Luca 5ccbcf6bec Backed out changeset b8146414348a (bug 1621306) for XPCShell failure in xpcshell/test_rotate_viewport.js 2020-03-11 03:41:29 +02:00
Micah Tigley ca85680174 Bug 1621306 - Enable the devtools.responsive.browserUI.enabled pref in Nightly only r=bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D66246

--HG--
extra : moz-landing-system : lando
2020-03-10 19:07:55 +00:00
Bryan Kok 2e03a48d33 Bug 1247083 - Number inline and new stylesheets separately in Style Editor; r=pbro
Differential Revision: https://phabricator.services.mozilla.com/D62019

--HG--
extra : moz-landing-system : lando
2020-03-09 15:50:29 +00:00
Mark Banner 15cfe23b88 Bug 1620542 - Automatically fix ESLint errors in .eslintrc.js files. r=mossop
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D65703

--HG--
extra : moz-landing-system : lando
2020-03-07 10:09:44 +00:00
Andreea Pavel c1fe06450c Bug 1424914 - disable browser_styleeditor_bug_1405342_serviceworker_iframes.js on win64 not debug r=gl
Differential Revision: https://phabricator.services.mozilla.com/D65686

--HG--
extra : moz-landing-system : lando
2020-03-06 14:14:24 +00:00
Alexandre Poirot 9e1daa2975 Bug 1585256 - Enable browser_styleeditor_fetch-from-netmonitor.js on fission. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D63185

--HG--
extra : moz-landing-system : lando
2020-02-18 15:37:19 +00:00
Alexandre Poirot a9af9ce5c0 Bug 1615283 - Converge random other navigation patterns to the unique navigateTo helper. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D62806

--HG--
extra : moz-landing-system : lando
2020-02-17 16:52:32 +00:00
Alexandre Poirot a858951923 Bug 1605763 - Wait for all target-available listeners resolution when calling TargetList.startListeners. r=jdescottes
Doing this helps ensuring that all async work done in panels,
when attaching to the top level target, to fetch already existing resources,
is fully completed before the test ends.

Differential Revision: https://phabricator.services.mozilla.com/D62554

--HG--
extra : moz-landing-system : lando
2020-02-13 13:46:13 +00:00
Dão Gottwald f07d464f9d Bug 1610497 - Increase browser window min-width so the address bar can be focused by mouse. r=mak
Differential Revision: https://phabricator.services.mozilla.com/D60960

--HG--
extra : moz-landing-system : lando
2020-01-30 15:59:29 +00:00
Daisuke Akatsuka c8b1cef022 Bug 1604126: Enable a styleeditor test that has been blocked by this bug. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D60795

--HG--
extra : moz-landing-system : lando
2020-01-23 14:14:13 +00:00