tor-browser

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

browser_animation_logic_mutations_fast.js (775B)


      1 /* Any copyright is dedicated to the Public Domain.
      2   http://creativecommons.org/publicdomain/zero/1.0/ */
      3 
      4 "use strict";
      5 
      6 // Test whether the animation inspector will not crash when remove/add animations faster.
      7 
      8 add_task(async function () {
      9  const tab = await addTab(URL_ROOT + "doc_mutations_fast.html");
     10  const { inspector } = await openAnimationInspector();
     11 
     12  info("Check state of the animation inspector after fast mutations");
     13  await startFastMutations(tab);
     14  ok(
     15    inspector.panelWin.document.getElementById("animation-container"),
     16    "Animation inspector should be live"
     17  );
     18 });
     19 
     20 async function startFastMutations(tab) {
     21  await SpecialPowers.spawn(tab.linkedBrowser, [], async function () {
     22    await content.wrappedJSObject.startFastMutations();
     23  });
     24 }