tor-browser

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

browser_animation_animation-detail_close-button.js (889B)


      1 /* Any copyright is dedicated to the Public Domain.
      2   http://creativecommons.org/publicdomain/zero/1.0/ */
      3 
      4 "use strict";
      5 
      6 // Test that whether close button in header of animation detail works.
      7 
      8 add_task(async function () {
      9  await addTab(URL_ROOT + "doc_custom_playback_rate.html");
     10  const { animationInspector, panel } = await openAnimationInspector();
     11 
     12  info("Checking close button in header of animation detail");
     13  await clickOnAnimation(animationInspector, panel, 0);
     14  const detailEl = panel.querySelector("#animation-container .controlled");
     15  const win = panel.ownerGlobal;
     16  isnot(
     17    win.getComputedStyle(detailEl).display,
     18    "none",
     19    "detailEl should be visibled before clicking close button"
     20  );
     21  clickOnDetailCloseButton(panel);
     22  is(
     23    win.getComputedStyle(detailEl).display,
     24    "none",
     25    "detailEl should be unvisibled after clicking close button"
     26  );
     27 });