From 5f8de423f190bbb79a62f804151bc24824fa32d8 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 2 Feb 2018 04:16:08 -0500 Subject: Add m-esr52 at 52.6.0 --- .../content/test/general/browser_findbarClose.js | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 browser/base/content/test/general/browser_findbarClose.js (limited to 'browser/base/content/test/general/browser_findbarClose.js') diff --git a/browser/base/content/test/general/browser_findbarClose.js b/browser/base/content/test/general/browser_findbarClose.js new file mode 100644 index 000000000..53503073c --- /dev/null +++ b/browser/base/content/test/general/browser_findbarClose.js @@ -0,0 +1,35 @@ +/* Any copyright is dedicated to the Public Domain. + http://creativecommons.org/publicdomain/zero/1.0/ */ + +// Tests find bar auto-close behavior + +var newTab; + +add_task(function* findbar_test() { + waitForExplicitFinish(); + newTab = gBrowser.addTab("about:blank"); + + let promise = ContentTask.spawn(newTab.linkedBrowser, null, function* () { + yield ContentTaskUtils.waitForEvent(this, "DOMContentLoaded", false); + }); + newTab.linkedBrowser.loadURI("http://example.com/browser/" + + "browser/base/content/test/general/test_bug628179.html"); + yield promise; + + gFindBar.open(); + + yield new ContentTask.spawn(newTab.linkedBrowser, null, function* () { + let iframe = content.document.getElementById("iframe"); + let awaitLoad = ContentTaskUtils.waitForEvent(iframe, "load", false); + iframe.src = "http://example.org/"; + yield awaitLoad; + }); + + ok(!gFindBar.hidden, "the Find bar isn't hidden after the location of a " + + "subdocument changes"); + + gFindBar.close(); + gBrowser.removeTab(newTab); + finish(); +}); + -- cgit v1.2.3