blob: 21b4e69a33e66da44595e991142b4ca6a7b326a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
add_task(async function test() {
window.open("about:blank", "", "width=100,height=100,noopener");
let win = Services.wm.getMostRecentWindow("navigator:browser");
Services.prefs.setBoolPref("browser.tabs.closeWindowWithLastTab", false);
win.gBrowser.removeCurrentTab();
ok(win.closed, "popup is closed");
// clean up
if (!win.closed) {
win.close();
}
Services.prefs.clearUserPref("browser.tabs.closeWindowWithLastTab");
});
|