tor-browser

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

test_animation_properties_display.html (979B)


      1 <!doctype html>
      2 <head>
      3 <meta charset=utf-8>
      4 <title>Bug 1536688 - Test that 'display' is not included in
      5  KeyframeEffect.getProperties() when using shorthand 'all'</title>
      6 <script type="application/javascript" src="../testharness.js"></script>
      7 <script type="application/javascript" src="../testharnessreport.js"></script>
      8 <script type="application/javascript" src="../testcommon.js"></script>
      9 </head>
     10 <body>
     11 <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1536688"
     12  target="_blank">Mozilla Bug 1536688</a>
     13 <div id="log"></div>
     14 <script>
     15 'use strict';
     16 
     17 test(t => {
     18  const div = addDiv(t);
     19  const animation = div.animate(
     20    { all: ['unset', 'unset'] },
     21    100 * MS_PER_SEC
     22  );
     23  // Flush styles since getProperties does not.
     24  getComputedStyle(div).opacity;
     25 
     26  const properties = animation.effect.getProperties();
     27  assert_false(
     28    properties.some(property => property.property === 'display'),
     29    'Should not have a property for display'
     30  );
     31 });
     32 
     33 </script>
     34 </body>