зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1690475 - [remote] Reorganize xpcshell and browser chrome tests. r=remote-protocol-reviewers,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D106062
This commit is contained in:
Родитель
23f1f53f83
Коммит
563458af7d
|
@ -158,7 +158,7 @@ python/
|
|||
|
||||
# These are (mainly) imported code that we don't want to lint to make imports easier.
|
||||
remote/cdp/Protocol.jsm
|
||||
remote/test/browser/chrome-remote-interface.js
|
||||
remote/cdp/test/browser/chrome-remote-interface.js
|
||||
|
||||
# services/ exclusions
|
||||
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
BROWSER_CHROME_MANIFESTS += [
|
||||
"test/browser/browser.ini",
|
||||
"test/browser/dom/browser.ini",
|
||||
"test/browser/emulation/browser.ini",
|
||||
"test/browser/input/browser.ini",
|
||||
"test/browser/io/browser.ini",
|
||||
"test/browser/log/browser.ini",
|
||||
"test/browser/network/browser.ini",
|
||||
"test/browser/page/browser.ini",
|
||||
"test/browser/runtime/browser.ini",
|
||||
"test/browser/security/browser.ini",
|
||||
"test/browser/target/browser.ini",
|
||||
]
|
||||
|
||||
XPCSHELL_TESTS_MANIFESTS += ["test/xpcshell/xpcshell.ini"]
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
|
||||
[browser_describeNode.js]
|
|
@ -6,6 +6,6 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
|
||||
[browser_setDeviceMetricsOverride.js]
|
|
@ -6,6 +6,6 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
|
@ -134,7 +134,7 @@ async function getCDP() {
|
|||
|
||||
const window = document.defaultView.wrappedJSObject;
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/chrome-remote-interface.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/chrome-remote-interface.js",
|
||||
window
|
||||
);
|
||||
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
doc_events.html
|
||||
doc_dispatchKeyEvent_race.html
|
|
@ -4,7 +4,7 @@
|
|||
"use strict";
|
||||
|
||||
const PAGE_URL =
|
||||
"http://example.com/browser/remote/test/browser/input/doc_events.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/input/doc_events.html";
|
||||
|
||||
add_task(async function testShiftEvents({ client }) {
|
||||
await setupForInput(PAGE_URL);
|
|
@ -27,7 +27,7 @@
|
|||
// in different processes.
|
||||
|
||||
const PAGE_URL =
|
||||
"http://example.com/browser/remote/test/browser/input/doc_dispatchKeyEvent_race.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/input/doc_dispatchKeyEvent_race.html";
|
||||
|
||||
add_task(async function({ client }) {
|
||||
await loadURL(PAGE_URL);
|
|
@ -6,7 +6,7 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
||||
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
|
||||
[browser_close.js]
|
|
@ -6,7 +6,7 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
||||
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
|
||||
[browser_entryAdded.js]
|
|
@ -6,6 +6,6 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
doc_empty.html
|
||||
doc_frameset.html
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const SJS_PATH = "/browser/remote/test/browser/network/sjs-cookies.sjs";
|
||||
const SJS_PATH = "/browser/remote/cdp/test/browser/network/sjs-cookies.sjs";
|
||||
|
||||
const DEFAULT_HOST = "http://example.org";
|
||||
const DEFAULT_HOSTNAME = "example.org";
|
||||
|
@ -230,9 +230,9 @@ add_task(async function forSpecificDomainAndURL({ client }) {
|
|||
add_task(async function path({ client }) {
|
||||
const { Network } = client;
|
||||
|
||||
const PATH = "/browser/remote/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/test/";
|
||||
const SUB_PATH = "/browser/remote/test/browser/network/";
|
||||
const PATH = "/browser/remote/cdp/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/cdp/test/";
|
||||
const SUB_PATH = "/browser/remote/cdp/test/browser/network/";
|
||||
|
||||
const cookie = {
|
||||
name: "foo",
|
|
@ -4,7 +4,7 @@
|
|||
"use strict";
|
||||
|
||||
const pageEmptyURL =
|
||||
"http://example.com/browser/remote/test/browser/page/doc_empty.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/doc_empty.html";
|
||||
|
||||
/**
|
||||
* Acts just as `add_task`, but does cleanup afterwards
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const SJS_PATH = "/browser/remote/test/browser/network/sjs-cookies.sjs";
|
||||
const SJS_PATH = "/browser/remote/cdp/test/browser/network/sjs-cookies.sjs";
|
||||
|
||||
const DEFAULT_HOST = "http://example.org";
|
||||
const ALT_HOST = "http://example.net";
|
||||
|
@ -143,8 +143,8 @@ add_task(async function session({ client }) {
|
|||
|
||||
add_task(async function path({ client }) {
|
||||
const { Network } = client;
|
||||
const PATH = "/browser/remote/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/test/";
|
||||
const PATH = "/browser/remote/cdp/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/cdp/test/";
|
||||
|
||||
await loadURL(`${DEFAULT_URL}?name=foo&value=bar&path=${PATH}`);
|
||||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const SJS_PATH = "/browser/remote/test/browser/network/sjs-cookies.sjs";
|
||||
const SJS_PATH = "/browser/remote/cdp/test/browser/network/sjs-cookies.sjs";
|
||||
|
||||
const DEFAULT_HOST = "http://example.org";
|
||||
const ALT_HOST = "http://example.net";
|
||||
|
@ -140,8 +140,8 @@ add_task(async function session({ client }) {
|
|||
|
||||
add_task(async function path({ client }) {
|
||||
const { Network } = client;
|
||||
const PATH = "/browser/remote/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/test/";
|
||||
const PATH = "/browser/remote/cdp/test/browser/";
|
||||
const PARENT_PATH = "/browser/remote/cdp/test/";
|
||||
|
||||
await loadURL(`${DEFAULT_URL}?name=foo&value=bar&path=${PATH}`);
|
||||
|
|
@ -6,7 +6,7 @@
|
|||
// Test order and consistency of Network/Page events as a whole.
|
||||
// Details of specific events are checked in event-specific test files.
|
||||
|
||||
const BASE_PATH = "http://example.com/browser/remote/test/browser/network";
|
||||
const BASE_PATH = "http://example.com/browser/remote/cdp/test/browser/network";
|
||||
const FRAMESET_URL = `${BASE_PATH}/doc_frameset.html`;
|
||||
const FRAMESET_JS_URL = `${BASE_PATH}/file_framesetEvents.js`;
|
||||
const PAGE_URL = `${BASE_PATH}/doc_networkEvents.html`;
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const BASE_PATH = "http://example.com/browser/remote/test/browser/network";
|
||||
const BASE_PATH = "http://example.com/browser/remote/cdp/test/browser/network";
|
||||
const FRAMESET_URL = `${BASE_PATH}/doc_frameset.html`;
|
||||
const FRAMESET_JS_URL = `${BASE_PATH}/file_framesetEvents.js`;
|
||||
const PAGE_URL = `${BASE_PATH}/doc_networkEvents.html`;
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const BASE_PATH = "http://example.com/browser/remote/test/browser/network";
|
||||
const BASE_PATH = "http://example.com/browser/remote/cdp/test/browser/network";
|
||||
const FRAMESET_URL = `${BASE_PATH}/doc_frameset.html`;
|
||||
const FRAMESET_JS_URL = `${BASE_PATH}/file_framesetEvents.js`;
|
||||
const PAGE_URL = `${BASE_PATH}/doc_networkEvents.html`;
|
|
@ -6,7 +6,7 @@
|
|||
const { INHIBIT_CACHING, LOAD_BYPASS_CACHE, LOAD_NORMAL } = Ci.nsIRequest;
|
||||
|
||||
const TEST_PAGE =
|
||||
"http://example.com/browser/remote/test/browser/network/doc_empty.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/network/doc_empty.html";
|
||||
|
||||
add_task(async function cacheEnabledAfterDisabled({ client }) {
|
||||
const { Network } = client;
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
const SJS_PATH = "/browser/remote/test/browser/network/sjs-cookies.sjs";
|
||||
const SJS_PATH = "/browser/remote/cdp/test/browser/network/sjs-cookies.sjs";
|
||||
|
||||
const DEFAULT_HOST = "example.org";
|
||||
const ALT_HOST = "foo.example.org";
|
|
@ -6,7 +6,7 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
||||
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
doc_empty.html
|
||||
sjs_redirect.sjs
|
|
@ -49,9 +49,9 @@ add_task(async function locationRedirect({ client }) {
|
|||
const { Page } = client;
|
||||
|
||||
const pageEmptyURL =
|
||||
"http://example.com/browser/remote/test/browser/page/doc_empty.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/doc_empty.html";
|
||||
const sjsURL =
|
||||
"http://example.com/browser/remote/test/browser/page/sjs_redirect.sjs";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/sjs_redirect.sjs";
|
||||
const redirectURL = `${sjsURL}?${pageEmptyURL}`;
|
||||
|
||||
const data = [
|
|
@ -13,7 +13,7 @@ const DOC_IFRAME_NESTED = toDataURL(`
|
|||
`);
|
||||
|
||||
const PAGE_URL =
|
||||
"http://example.com/browser/remote/test/browser/page/doc_empty.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/doc_empty.html";
|
||||
|
||||
add_task(async function noEventsWhenPageDomainDisabled({ client }) {
|
||||
await runPageLifecycleTest(client, 0, async () => {
|
|
@ -4,7 +4,7 @@
|
|||
"use strict";
|
||||
|
||||
const pageEmptyURL =
|
||||
"http://example.com/browser/remote/test/browser/page/doc_empty.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/doc_empty.html";
|
||||
|
||||
add_task(async function testBasicNavigation({ client }) {
|
||||
const { Page, Network } = client;
|
||||
|
@ -91,7 +91,7 @@ add_task(async function testTwoNavigations({ client }) {
|
|||
add_task(async function testRedirect({ client }) {
|
||||
const { Page, Network } = client;
|
||||
const sjsURL =
|
||||
"http://example.com/browser/remote/test/browser/page/sjs_redirect.sjs";
|
||||
"http://example.com/browser/remote/cdp/test/browser/page/sjs_redirect.sjs";
|
||||
const redirectURL = `${sjsURL}?${pageEmptyURL}`;
|
||||
await Page.enable();
|
||||
await Network.enable();
|
|
@ -6,7 +6,7 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
||||
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
doc_console_events.html
|
||||
head.js
|
||||
|
|
@ -4,7 +4,7 @@
|
|||
"use strict";
|
||||
|
||||
const PAGE_CONSOLE_EVENTS =
|
||||
"http://example.com/browser/remote/test/browser/runtime/doc_console_events.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/runtime/doc_console_events.html";
|
||||
|
||||
add_task(async function noEventsWhenRuntimeDomainDisabled({ client }) {
|
||||
await runConsoleTest(client, 0, async () => {
|
|
@ -4,7 +4,7 @@
|
|||
"use strict";
|
||||
|
||||
const PAGE_CONSOLE_EVENTS =
|
||||
"http://example.com/browser/remote/test/browser/runtime/doc_console_events.html";
|
||||
"http://example.com/browser/remote/cdp/test/browser/runtime/doc_console_events.html";
|
||||
|
||||
add_task(async function noEventsWhenRuntimeDomainDisabled({ client }) {
|
||||
await runExceptionThrownTest(client, 0, async () => {
|
|
@ -6,6 +6,6 @@
|
|||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/test/browser/head.js",
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
|
||||
[browser_setIgnoreCertificateErrors.js]
|
|
@ -0,0 +1,11 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
"use strict";
|
||||
|
||||
/* import-globals-from ../head.js */
|
||||
|
||||
Services.scriptloader.loadSubScript(
|
||||
"chrome://mochitests/content/browser/remote/cdp/test/browser/head.js",
|
||||
this
|
||||
);
|
|
@ -4,8 +4,8 @@ subsuite = remote
|
|||
prefs =
|
||||
remote.enabled=true
|
||||
support-files =
|
||||
!/remote/test/browser/chrome-remote-interface.js
|
||||
!/remote/test/browser/head.js
|
||||
!/remote/cdp/test/browser/chrome-remote-interface.js
|
||||
!/remote/cdp/test/browser/head.js
|
||||
head.js
|
||||
doc_test.html
|
||||
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче