Backed out changeset 7dc106b54960 (bug 1147911)
authorSebastian Hengst <archaeopteryx@coole-files.de>
Wed, 23 Nov 2016 18:33:02 +0100
changeset 324115 fc8e1019ebff3a7fccab860f338dc83930f6b6a7
parent 324114 2abf973bfdca422d9b38de8005c37446d47c4f35
child 324116 feadf85d42ecbf5ab59d36fc7e86beb7fde54a6a
push id24
push usermaklebus@msu.edu
push dateTue, 20 Dec 2016 03:11:33 +0000
bugs1147911
milestone53.0a1
backs out7dc106b5496086c1b25bc8e321432b26ae8114ea
Backed out changeset 7dc106b54960 (bug 1147911)
devtools/client/webconsole/test/browser_webconsole_bug_595223_file_uri.js
devtools/client/webconsole/test/head.js
--- a/devtools/client/webconsole/test/browser_webconsole_bug_595223_file_uri.js
+++ b/devtools/client/webconsole/test/browser_webconsole_bug_595223_file_uri.js
@@ -2,33 +2,32 @@
 /* vim: set ft=javascript ts=2 et sw=2 tw=80: */
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
 "use strict";
 
 const PREF = "devtools.webconsole.persistlog";
 const TEST_FILE = "test-network.html";
+const TEST_URI = "data:text/html;charset=utf8,<p>test file URI";
 
 var hud;
 
 add_task(function* () {
   Services.prefs.setBoolPref(PREF, true);
 
   let jar = getJar(getRootDirectory(gTestPath));
   let dir = jar ?
             extractJarToTmp(jar) :
             getChromeDir(getResolvedURI(gTestPath));
 
   dir.append(TEST_FILE);
   let uri = Services.io.newFileURI(dir);
 
-  // We need a file remote type to make sure we don't switch processes when we
-  // load the file:// URI.
-  let { browser } = yield loadTab("about:blank", "file");
+  let { browser } = yield loadTab(TEST_URI);
 
   hud = yield openConsole();
   hud.jsterm.clearOutput();
 
   let loaded = loadBrowser(browser);
   BrowserTestUtils.loadURI(gBrowser.selectedBrowser, uri.spec);
   yield loaded;
 
--- a/devtools/client/webconsole/test/head.js
+++ b/devtools/client/webconsole/test/head.js
@@ -41,20 +41,20 @@ const WEBCONSOLE_STRINGS_URI = "devtools
 var WCUL10n = new WebConsoleUtils.L10n(WEBCONSOLE_STRINGS_URI);
 
 const DOCS_GA_PARAMS = "?utm_source=mozilla" +
                        "&utm_medium=firefox-console-errors" +
                        "&utm_campaign=default";
 
 flags.testing = true;
 
-function loadTab(url, preferredRemoteType) {
+function loadTab(url) {
   let deferred = promise.defer();
 
-  let tab = gBrowser.selectedTab = gBrowser.addTab(url, { preferredRemoteType });
+  let tab = gBrowser.selectedTab = gBrowser.addTab(url);
   let browser = gBrowser.getBrowserForTab(tab);
 
   browser.addEventListener("load", function onLoad() {
     browser.removeEventListener("load", onLoad, true);
     deferred.resolve({tab: tab, browser: browser});
   }, true);
 
   return deferred.promise;