Bug 1444287, wait for the right page to load before performing the test, otherwise about:blank sometimes gets used, r=Gijs
authorNeil Deakin <neil@mozilla.com>
Thu, 14 Nov 2019 16:23:18 +0000
changeset 502129 4817e5961588294d16d7e194ed843b402bd48768
parent 502128 903da4a7bbe1b096bedecbd42ab89bf5c67c0ef5
child 502130 fd63a50a812ec869d3e17e86f9a89ed47c8f1671
push id114172
push userdluca@mozilla.com
push dateTue, 19 Nov 2019 11:31:10 +0000
treeherdermozilla-inbound@b5c5ba07d3db [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersGijs
bugs1444287
milestone72.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 1444287, wait for the right page to load before performing the test, otherwise about:blank sometimes gets used, r=Gijs Differential Revision: https://phabricator.services.mozilla.com/D52940
browser/base/content/test/general/browser_documentnavigation.js
--- a/browser/base/content/test/general/browser_documentnavigation.js
+++ b/browser/base/content/test/general/browser_documentnavigation.js
@@ -119,17 +119,21 @@ async function expectFocusOnF6(
       "BrowserTest:FocusChanged",
       focusChangedListener
     );
   }
 }
 
 // Load a page and navigate between it and the chrome window.
 add_task(async function() {
-  let page1Promise = BrowserTestUtils.browserLoaded(gBrowser.selectedBrowser);
+  let page1Promise = BrowserTestUtils.browserLoaded(
+    gBrowser.selectedBrowser,
+    false,
+    testPage1
+  );
   BrowserTestUtils.loadURI(gBrowser.selectedBrowser, testPage1);
   await page1Promise;
 
   // When the urlbar is focused, pressing F6 should focus the root of the content page.
   gURLBar.focus();
   await expectFocusOnF6(
     false,
     "html1",