1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/browser/base/content/test/general/browser_bug581242.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,21 @@ 1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.7 + 1.8 +function test() { 1.9 + // Create a new tab and load about:addons 1.10 + let blanktab = gBrowser.addTab(); 1.11 + gBrowser.selectedTab = blanktab; 1.12 + BrowserOpenAddonsMgr(); 1.13 + 1.14 + is(blanktab, gBrowser.selectedTab, "Current tab should be blank tab"); 1.15 + // Verify that about:addons loads 1.16 + waitForExplicitFinish(); 1.17 + gBrowser.selectedBrowser.addEventListener("load", function() { 1.18 + gBrowser.selectedBrowser.removeEventListener("load", arguments.callee, true); 1.19 + let browser = blanktab.linkedBrowser; 1.20 + is(browser.currentURI.spec, "about:addons", "about:addons should load into blank tab."); 1.21 + gBrowser.removeTab(blanktab); 1.22 + finish(); 1.23 + }, true); 1.24 +}