summaryrefslogtreecommitdiffstats
path: root/browser/base/content/test/general/browser_bug479408.js
blob: 0dfa96f2ef2360caa3e116e87c59bccdfcdd1102 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
function test() {
  waitForExplicitFinish();
  let tab = gBrowser.selectedTab = gBrowser.addTab(
    "http://mochi.test:8888/browser/browser/base/content/test/general/browser_bug479408_sample.html");

  gBrowser.addEventListener("DOMLinkAdded", function(aEvent) {
    gBrowser.removeEventListener("DOMLinkAdded", arguments.callee, true);

    executeSoon(function() {
      ok(!tab.linkedBrowser.engines,
         "the subframe's search engine wasn't detected");

      gBrowser.removeTab(tab);
      finish();
    });
  }, true);
}