tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

browser_parent_has_pip_flag.js (545B)


      1 /* Any copyright is dedicated to the Public Domain.
      2   http://creativecommons.org/publicdomain/zero/1.0/ */
      3 
      4 "use strict";
      5 
      6 add_task(async function check_chrome_window_has_pip_flag() {
      7  const [tab, chromePiP] = await newTabWithPiP();
      8 
      9  is(
     10    chromePiP.location.href,
     11    "chrome://browser/content/browser.xhtml",
     12    "Got the chrome window of the PiP"
     13  );
     14  ok(chromePiP.browsingContext.isDocumentPiP, "Chrome window has pip flag set");
     15 
     16  // Cleanup.
     17  await BrowserTestUtils.closeWindow(chromePiP);
     18  BrowserTestUtils.removeTab(tab);
     19 });