Backed out changeset 7d9cd61d95ce (bug 1742351) for causing bc failures on browser_paste_event_at_middle_click_on_link.js. CLOSED TREE

This commit is contained in:
Iulian Moraru 2021-11-22 14:14:16 +02:00
Родитель e062e3d465
Коммит 91d2056266
7 изменённых файлов: 20 добавлений и 21 удалений

Просмотреть файл

@ -5,7 +5,7 @@
// Test for the docshell active state of local and remote browsers.
const kTestPage =
"https://example.org/browser/browser/base/content/test/general/dummy_page.html";
"http://example.org/browser/browser/base/content/test/general/dummy_page.html";
function promiseNewTabSwitched() {
return new Promise(resolve => {

Просмотреть файл

@ -34,7 +34,7 @@ add_task(async function doCheckPasteEventAtMiddleClickOnAnchorElement() {
let pageURL = getRootDirectory(gTestPath).replace(
"chrome://mochitests/content",
"https://example.com"
"http://example.com"
);
pageURL = `${pageURL}file_anchor_elements.html`;
let tab = await BrowserTestUtils.openNewForegroundTab(gBrowser, pageURL);
@ -52,7 +52,7 @@ add_task(async function doCheckPasteEventAtMiddleClickOnAnchorElement() {
ok(true, "Clicking on usual link...");
let newTabPromise = BrowserTestUtils.waitForNewTab(
gBrowser,
"https://example.com/#a_with_href",
"http://example.com/#a_with_href",
true
);
await BrowserTestUtils.synthesizeMouseAtCenter(
@ -63,7 +63,7 @@ add_task(async function doCheckPasteEventAtMiddleClickOnAnchorElement() {
let openTabForUsualLink = await newTabPromise;
is(
openTabForUsualLink.linkedBrowser.currentURI.spec,
"https://example.com/#a_with_href",
"http://example.com/#a_with_href",
"Middle click should open site to correct url at clicking on usual link"
);
is(
@ -103,7 +103,7 @@ add_task(async function doCheckPasteEventAtMiddleClickOnAnchorElement() {
ok(true, "Clicking on non-editable link in an editing host...");
newTabPromise = BrowserTestUtils.waitForNewTab(
gBrowser,
"https://example.com/#non-editable_a_with_href",
"http://example.com/#non-editable_a_with_href",
true
);
await BrowserTestUtils.synthesizeMouseAtCenter(
@ -114,7 +114,7 @@ add_task(async function doCheckPasteEventAtMiddleClickOnAnchorElement() {
let openTabForNonEditableLink = await newTabPromise;
is(
openTabForNonEditableLink.linkedBrowser.currentURI.spec,
"https://example.com/#non-editable_a_with_href",
"http://example.com/#non-editable_a_with_href",
"Middle click should open site to correct url at clicking on non-editable link in an editing host."
);
is(

Просмотреть файл

@ -51,22 +51,22 @@ add_task(async function test_create_options() {
let tests = [
{
create: { url: "https://example.com/" },
result: { url: "https://example.com/" },
create: { url: "http://example.com/" },
result: { url: "http://example.com/" },
},
{
create: { url: "view-source:https://example.com/" },
result: { url: "view-source:https://example.com/" },
create: { url: "view-source:http://example.com/" },
result: { url: "view-source:http://example.com/" },
},
{
create: { url: "blank.html" },
result: { url: browser.runtime.getURL("bg/blank.html") },
},
{
create: { url: "https://example.com/", openInReaderMode: true },
create: { url: "http://example.com/", openInReaderMode: true },
result: {
url: `about:reader?url=${encodeURIComponent(
"https://example.com/"
"http://example.com/"
)}`,
},
},

Просмотреть файл

@ -340,12 +340,12 @@ add_task(async function testTabEventsSize() {
browser.test.onMessage.addListener(async (msg, arg) => {
if (msg === "create-tab") {
let tab = await browser.tabs.create({ url: "https://example.com/" });
let tab = await browser.tabs.create({ url: "http://example.com/" });
sendSizeMessages(tab, "create");
browser.test.sendMessage("created-tab-id", tab.id);
} else if (msg === "update-tab") {
let tab = await browser.tabs.update(arg, {
url: "https://example.org/",
url: "http://example.org/",
});
sendSizeMessages(tab, "update");
} else if (msg === "remove-tab") {
@ -462,7 +462,7 @@ add_task(async function testTabRemovalEvent() {
try {
let url =
"https://example.com/browser/browser/components/extensions/test/browser/context.html";
"http://example.com/browser/browser/components/extensions/test/browser/context.html";
let tab = await browser.tabs.create({ url: url });
await awaitLoad(tab.id);
@ -538,7 +538,7 @@ add_task(async function testTabCreateRelated() {
// Create a *opener* tab page which has a link to "example.com".
let pageURL =
"https://example.com/browser/browser/components/extensions/test/browser/file_dummy.html";
"http://example.com/browser/browser/components/extensions/test/browser/file_dummy.html";
let openerTab = await BrowserTestUtils.openNewForegroundTab(
gBrowser,
pageURL
@ -549,7 +549,7 @@ add_task(async function testTabCreateRelated() {
let newTabPromise = BrowserTestUtils.waitForNewTab(
gBrowser,
"https://example.com/#linkclick",
"http://example.com/#linkclick",
true
);
await BrowserTestUtils.synthesizeMouseAtCenter(
@ -560,7 +560,7 @@ add_task(async function testTabCreateRelated() {
let openTab = await newTabPromise;
is(
openTab.linkedBrowser.currentURI.spec,
"https://example.com/#linkclick",
"http://example.com/#linkclick",
"Middle click should open site to correct url."
);
BrowserTestUtils.removeTab(openTab);

Просмотреть файл

@ -2,7 +2,7 @@
let BASE_URL = getRootDirectory(gTestPath).replace(
"chrome://mochitests/content/",
"https://example.com/"
"http://example.com/"
);
const TEST_URL = BASE_URL + "pageopeningwindow.html";
const DUMMY_URL = BASE_URL + "bookmarklet_windowOpen_dummy.html";

Просмотреть файл

@ -3,7 +3,7 @@
"use strict";
const REMOTE_URL = "https://www.example.com/";
const REMOTE_URL = "http://www.example.com/";
const ABOUT_ROBOTS_URL = "about:robots";
const NO_TITLE_URL = "data:text/plain,foo";

Просмотреть файл

@ -460,7 +460,6 @@ var BrowserTestUtils = {
// the load to https://.
if (
BrowserTestUtils._httpsFirstEnabled &&
typeof wantLoad == "string" &&
wantLoad.startsWith("http://")
) {
let wantLoadHttps = wantLoad.replace("http://", "https://");