Bug 1472212 - Load `http://example.org/` instead of `about:home` for some tests. r=Gijs
☠☠ backed out by dff3cfb50f19 ☠ ☠
authorJay Lim <jlim@mozilla.com>
Fri, 20 Jul 2018 18:49:59 -0400
changeset 443504 7b7fa6ab2229
parent 443503 4fe4ec18f2f3
child 443505 95a7ef6102a6
push id109403
push usermconley@mozilla.com
push dateTue, 30 Oct 2018 18:39:04 +0000
treeherdermozilla-inbound@aa35078cabaa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersGijs
bugs1472212, 1336811, 1242643
milestone65.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1472212 - Load `http://example.org/` instead of `about:home` for some tests. r=Gijs These tests were timing out because `about:home` now runs in a different process. Since these two tests aim to test something else (e.g. window leaks when navigating between pages), we will redirect to a URL that loads in the same process instead of `about:home` to avoid adding extra conditions for the process flip. See Bug 1336811 and Bug 1242643. MozReview-Commit-ID: G0rhfA973R9
dom/xhr/tests/browser_xhr_onchange_leak.js
js/xpconnect/tests/browser/browser_dead_object.js
--- a/dom/xhr/tests/browser_xhr_onchange_leak.js
+++ b/dom/xhr/tests/browser_xhr_onchange_leak.js
@@ -6,18 +6,18 @@
 // Bug 1336811 - An XHR that has a .onreadystatechange waiting should
 // not leak forever once the tab is closed. CC optimizations need to be
 // turned off once it is closed.
 
 add_task(async function test() {
   const url = "http://mochi.test:8888/browser/dom/xhr/tests/browser_xhr_onchange_leak.html";
   let newTab = await BrowserTestUtils.openNewForegroundTab(gBrowser, url);
   let browser = gBrowser.selectedBrowser;
-  let done = await ContentTask.spawn(browser,{}, async function(browser){
+  let done = await ContentTask.spawn(browser, {}, async function(browser) {
     let doc = content.document;
     let promise = ContentTaskUtils.waitForEvent(this, "DOMContentLoaded", true);
-    content.location = "about:home";
+    content.location = "http://example.org/";
     await promise;
     return true;
   });
   is(done, true, "need to check something");
   BrowserTestUtils.removeTab(newTab);
 });
--- a/js/xpconnect/tests/browser/browser_dead_object.js
+++ b/js/xpconnect/tests/browser/browser_dead_object.js
@@ -5,22 +5,22 @@
 
 // For bug 773980, test that Components.utils.isDeadWrapper works as expected.
 
 add_task(async function test() {
   const url = "http://mochi.test:8888/browser/js/xpconnect/tests/browser/browser_deadObjectOnUnload.html";
   let newTab = await BrowserTestUtils.openNewForegroundTab(gBrowser, url);
   let browser = gBrowser.selectedBrowser;
   let innerWindowId = browser.innerWindowID;
-  let contentDocDead = await ContentTask.spawn(browser,{innerWindowId}, async function(args){
+  let contentDocDead = await ContentTask.spawn(browser, {innerWindowId}, async function(args) {
     let doc = content.document;
     let {TestUtils} = ChromeUtils.import("resource://testing-common/TestUtils.jsm", {});
     let promise = TestUtils.topicObserved("inner-window-nuked", (subject, data) => {
       let id = subject.QueryInterface(Ci.nsISupportsPRUint64).data;
       return id == args.innerWindowId;
     });
-    content.location = "about:home";
+    content.location = "http://example.org/";
     await promise;
     return Cu.isDeadWrapper(doc);
   });
   is(contentDocDead, true, "wrapper is dead");
-  BrowserTestUtils.removeTab(newTab); 
+  BrowserTestUtils.removeTab(newTab);
 });