/* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ const tabAPI = require("tabs/tab"); const tabs = require("tabs"); // From addon-kit const windowUtils = require("window-utils"); // The primary test tab var primaryTab; // We have an auxiliary tab to test background tabs. var auxTab; // The window for the outer iframe in the primary test page var iframeWin; exports.testGetTabForWindow = function(test) { test.waitUntilDone(); test.assertEqual(tabAPI.getTabForWindow(windowUtils.activeWindow), null, "getTabForWindow return null on topwindow"); test.assertEqual(tabAPI.getTabForWindow(windowUtils.activeBrowserWindow), null, "getTabForWindow return null on topwindow"); let subSubDocument = encodeURIComponent( 'Sub iframe
'+ '