Bug 1047603 - Make Marionette server force the initial browser to be remote when in an e10s window. r=chmanchester.
authorMike Conley <mconley@mozilla.com>
Thu, 05 Feb 2015 17:56:43 -0500
changeset 228526 179ab8bb80aeb209b9c7ce2565defa1395ed9e02
parent 228525 be43b4de674dac19ea48a5ed23d7bb64fca734fd
child 228527 ed3e996b3805c641dbda53c83907f87d3302995a
push id28264
push usercbook@mozilla.com
push dateWed, 11 Feb 2015 13:58:35 +0000
treeherdermozilla-central@38058cb42a0e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerschmanchester
bugs1047603, 1096488
milestone38.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 1047603 - Make Marionette server force the initial browser to be remote when in an e10s window. r=chmanchester. Workaround until bug 1096488 gets fixed. A newly opened e10s window has an initial browser that is not remote, but that transitions to become remote as soon as it attempts to load a document. Marionette, unfortunately, is not prepared at this time to deal with transitions between remote and non-remote browsers. We work around this by forcing the initial browser to be remote when the window opens.
testing/marionette/marionette-server.js
--- a/testing/marionette/marionette-server.js
+++ b/testing/marionette/marionette-server.js
@@ -3191,16 +3191,21 @@ BrowserObj.prototype = {
         this.browser = win.BrowserApp;
         break;
     }
   },
   /**
    * Called when we start a session with this browser.
    */
   startSession: function BO_startSession(newSession, win, callback) {
+    if (appName == "Firefox" &&
+        win.gMultiProcessBrowser &&
+        !win.gBrowser.selectedBrowser.isRemoteBrowser) {
+      win.XULBrowserWindow.forceInitialBrowserRemote();
+    }
     callback(win, newSession);
   },
 
   /**
    * Closes current tab
    */
   closeTab: function BO_closeTab() {
     if (this.browser &&