www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit b241d3ec528a37f2bbe6ff1bcf3fb577633b92f2
parent f4b6e228173940068013533a03fba6988a394e34
Author: Dan Stillman <dstillman@zotero.org>
Date:   Sun, 26 Apr 2015 16:48:34 -0400

Add loadBrowserWindow() test support function

Diffstat:
Mtest/content/support.js | 11++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/test/content/support.js b/test/content/support.js @@ -23,10 +23,19 @@ function loadWindow(winurl, argument) { } /** + * Open a browser window and return a promise for the window + * + * @return {Promise<ChromeWindow>} + */ +function loadBrowserWindow() { + return loadWindow("chrome://browser/content/browser.xul"); +} + +/** * Loads a Zotero pane in a new window. Returns the containing window. */ function loadZoteroPane() { - return loadWindow("chrome://browser/content/browser.xul").then(function(win) { + return loadBrowserWindow().then(function(win) { win.ZoteroOverlay.toggleDisplay(true); // Hack to wait for pane load to finish. This is the same hack