Changeset 258572 in webkit


Ignore:
Timestamp:
Mar 17, 2020 12:39:47 PM (4 years ago)
Author:
graouts@webkit.org
Message:

http/wpt/css/css-animations/start-animation-001.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207337
<rdar://problem/59226371>

Reviewed by Dean Jackson.

This test was written in a flaky way for two reasons:

  1. it was using a timer to assume state in the animation engine
  2. it was using an accelerated animation that wasn't absolutely required to as an indicator of what a non-steps based version of the tested animation would look like, but accelerated animations are notoriously hard to test for rendering purposes

We update the test to use the secondary animation as a timer so that we can test the state of animations at 200ms precisely,
and we get rid of the accelerated animation such that only the tested animation's rendering is tested.

  • http/wpt/css/css-animations/start-animation-001.html:
  • platform/mac/TestExpectations:
Location:
trunk/LayoutTests
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r258571 r258572  
     12020-03-17  Antoine Quint  <graouts@apple.com>
     2
     3        http/wpt/css/css-animations/start-animation-001.html is flaky failing
     4        https://bugs.webkit.org/show_bug.cgi?id=207337
     5        <rdar://problem/59226371>
     6
     7        Reviewed by Dean Jackson.
     8
     9        This test was written in a flaky way for two reasons:
     10       
     11        1. it was using a timer to assume state in the animation engine
     12        2. it was using an accelerated animation that wasn't absolutely required to as an indicator of what a non-steps based version
     13           of the tested animation would look like, but accelerated animations are notoriously hard to test for rendering purposes
     14
     15        We update the test to use the secondary animation as a timer so that we can test the state of animations at 200ms precisely,
     16        and we get rid of the accelerated animation such that only the tested animation's rendering is tested.
     17
     18        * http/wpt/css/css-animations/start-animation-001.html:
     19        * platform/mac/TestExpectations:
     20
    1212020-03-17  Antoine Quint  <graouts@apple.com>
    222
  • trunk/LayoutTests/http/wpt/css/css-animations/start-animation-001.html

    r239656 r258572  
    1717      }
    1818      /* Avoid animation-fill-mode, to make sure that the move is done by the animation code. */
    19       #squareLinear {
    20         top: 0px;
    21         animation: moveByTransform 10s linear;
    22       }
    2319      #squareSteps {
    2420        top: 150px;
     
    2723      #squareNonAccelerated  {
    2824        top: 300px;
    29         animation: moveByLeft 10s steps(100);
     25        animation: moveByLeft 200ms steps(10) forwards;
    3026      }
    3127      @keyframes moveByTransform
     
    4137        }
    4238        100% {
    43           left: 5000px;
     39          left: 90px;
    4440        }
    4541      }
     
    5450    </style>
    5551    <script>
    56       function runTest() {
    57         if (!window.testRunner)
    58           return;
    59         // We wait a bit after the squares are moved behind the blue rectangle. For discontinuous
    60         // transforms we have 5000px / 100 steps = 5px/step. Hence this happens after 20 steps i.e.
    61         // 20/100*10s = 200ms.
    62         testRunner.waitUntilDone();
    63         setTimeout(() => { testRunner.notifyDone(); }, 300);
    64       }
     52      window.addEventListener("DOMContentLoaded", () => {
     53          if (!window.testRunner)
     54            return;
     55          // We wait a bit after the squares are moved behind the blue rectangle. For discontinuous
     56          // transforms we have 5000px / 100 steps = 5px/step. Hence this happens after 20 steps i.e.
     57          // 20/100*10s = 200ms.
     58          testRunner.waitUntilDone();
     59          document.getElementById("squareNonAccelerated").addEventListener("animationend", () => testRunner.notifyDone());
     60      });
    6561    </script>
    6662  </head>
    67   <body onload="runTest()">
     63  <body>
    6864    <p>This test passes if green squares are moved behind the blue rectangle.</p>
    6965    <div id="container">
    70       <div id="squareLinear"><tt>transform</tt> (linear)</div>
    7166      <div id="squareSteps"><tt>transform</tt> (steps)</div>
    7267      <div id="squareNonAccelerated"><tt>left</tt> (steps)</div>
  • trunk/LayoutTests/platform/mac/TestExpectations

    r258563 r258572  
    19821982webkit.org/b/194162 storage/websql/read-transactions-running-concurrently.html [ Pass Failure ]
    19831983
    1984 webkit.org/b/207337 http/wpt/css/css-animations/start-animation-001.html [ Pass ImageOnlyFailure ]
    1985 
    19861984webkit.org/b/207710 svg/custom/animate-initial-pause-unpause.html [ Pass Failure ]
    19871985
Note: See TracChangeset for help on using the changeset viewer.