From 0f541d7b81d2aecb38c00ddeec0153e2b88bf432 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A3o=20Gottwald?= Date: Thu, 20 Nov 2014 14:36:04 +0100 Subject: [PATCH] Bug 1102018 - Fix and enable browser_bug481560.js for e10s. r=gijs --- browser/base/content/test/general/browser.ini | 1 - .../base/content/test/general/browser_bug481560.js | 14 ++++---------- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/browser/base/content/test/general/browser.ini b/browser/base/content/test/general/browser.ini index 333dc2ff09b3..612d09a350ef 100644 --- a/browser/base/content/test/general/browser.ini +++ b/browser/base/content/test/general/browser.ini @@ -179,7 +179,6 @@ skip-if = e10s # Bug 1093206 - need to re-enable tests relying on swapFrameLoade [browser_bug479408.js] skip-if = buildapp == 'mulet' [browser_bug481560.js] -skip-if = e10s # Bug 1102018 - This bug attaches an event listener directly to the content, which then never gets called. [browser_bug484315.js] skip-if = e10s [browser_bug491431.js] diff --git a/browser/base/content/test/general/browser_bug481560.js b/browser/base/content/test/general/browser_bug481560.js index e3d281b1b905..bb9249e755df 100644 --- a/browser/base/content/test/general/browser_bug481560.js +++ b/browser/base/content/test/general/browser_bug481560.js @@ -1,14 +1,8 @@ function test() { waitForExplicitFinish(); - var win = openDialog(getBrowserURL(), "_blank", "chrome,all,dialog=no"); - - win.addEventListener("load", function () { - win.removeEventListener("load", arguments.callee, false); - - win.content.addEventListener("focus", function () { - win.content.removeEventListener("focus", arguments.callee, false); - + whenNewWindowLoaded(null, function (win) { + waitForFocus(function () { function onTabClose() { ok(false, "shouldn't have gotten the TabClose event for the last tab"); } @@ -22,6 +16,6 @@ function test() { tab.removeEventListener("TabClose", onTabClose, false); finish(); - }, false); - }, false); + }, win); + }); }