Bug 1511856 - Ensure the URL bar isn't hovered when starting browser_UrlbarInput_tooltip.js. r=mak
authorDão Gottwald <dao@mozilla.com>
Tue, 04 Dec 2018 19:35:01 +0000
changeset 508530 94582b9363c6d7759a996ad49ce92d52fd62eba8
parent 508529 24a3e091070c0f89b34760a110e2d794ad923bcf
child 508531 5dca9c949ba4b969ba486d5926a79c7dba8e15c8
push id1905
push userffxbld-merge
push dateMon, 21 Jan 2019 12:33:13 +0000
treeherdermozilla-release@c2fca1944d8c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmak
bugs1511856
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 1511856 - Ensure the URL bar isn't hovered when starting browser_UrlbarInput_tooltip.js. r=mak Differential Revision: https://phabricator.services.mozilla.com/D13685
browser/components/urlbar/tests/browser/browser_UrlbarInput_tooltip.js
--- a/browser/components/urlbar/tests/browser/browser_UrlbarInput_tooltip.js
+++ b/browser/components/urlbar/tests/browser/browser_UrlbarInput_tooltip.js
@@ -59,18 +59,19 @@ async function expectNoTooltip() {
 }
 
 add_task(async function() {
   window.windowUtils.disableNonTestMouseEvents(true);
   registerCleanupFunction(() => {
     window.windowUtils.disableNonTestMouseEvents(false);
   });
 
-  // Ensure the URL bar isn't focused.
+  // Ensure the URL bar is neither focused nor hovered before we start.
   gBrowser.selectedBrowser.focus();
+  await synthesizeMouseOut(gURLBar.inputField);
 
   gURLBar.value = "short string";
   await expectNoTooltip();
 
   let longURL = "http://longurl.com/" + "foobar/".repeat(30);
   gURLBar.value = longURL;
   is(gURLBar.inputField.value, longURL.replace(/^http:\/\//, ""), "Urlbar value has http:// stripped");
   await expectTooltip(longURL);