diff options
Diffstat (limited to 'browser/base/content/test/urlbar/browser_moz_action_link.js')
-rw-r--r-- | browser/base/content/test/urlbar/browser_moz_action_link.js | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/browser/base/content/test/urlbar/browser_moz_action_link.js b/browser/base/content/test/urlbar/browser_moz_action_link.js deleted file mode 100644 index ed2d36ee5..000000000 --- a/browser/base/content/test/urlbar/browser_moz_action_link.js +++ /dev/null @@ -1,31 +0,0 @@ -"use strict"; - -const kURIs = [ - "moz-action:foo,", - "moz-action:foo", -]; - -add_task(function*() { - for (let uri of kURIs) { - let dataURI = `data:text/html,<a id=a href="${uri}" target=_blank>Link</a>`; - let tab = yield BrowserTestUtils.openNewForegroundTab(gBrowser, dataURI); - - let tabSwitchPromise = BrowserTestUtils.switchTab(gBrowser, function() {}); - yield ContentTask.spawn(tab.linkedBrowser, null, function*() { - content.document.getElementById("a").click(); - }); - yield tabSwitchPromise; - isnot(gBrowser.selectedTab, tab, "Switched to new tab!"); - is(gURLBar.value, "about:blank", "URL bar should be displaying about:blank"); - let newTab = gBrowser.selectedTab; - yield BrowserTestUtils.switchTab(gBrowser, tab); - yield BrowserTestUtils.switchTab(gBrowser, newTab); - is(gBrowser.selectedTab, newTab, "Switched to new tab again!"); - is(gURLBar.value, "about:blank", "URL bar should be displaying about:blank after tab switch"); - // Finally, check that directly setting it produces the right results, too: - URLBarSetURI(makeURI(uri)); - is(gURLBar.value, "about:blank", "URL bar should still be displaying about:blank"); - yield BrowserTestUtils.removeTab(newTab); - yield BrowserTestUtils.removeTab(tab); - } -}); |