Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(329)

Side by Side Diff: third_party/WebKit/LayoutTests/virtual/threaded/animations/KeyframeEffectReadOnly-composited-animation.html

Issue 2398373002: Construct KeyframeEffectReadOnly objects (Closed)
Patch Set: Test tweaks in response to review Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <meta charset=utf-8>
3 <title>Animating with KeyframeEffectReadOnly objects</title>
4 <script src="../../../resources/testharness.js"></script>
5 <script src="../../../resources/testharnessreport.js"></script>
6 <body>
7 <div id="target"></div>
8 <div id="targetRO"></div>
9 <script>
10 "use strict";
11
12 promise_test(function(t) {
13 var effect = new KeyframeEffect(target, { opacity: [0, 0.9] }, 1000);
14 var anim = target.animate(null);
15 anim.effect = effect;
16
17 var effectRO = new KeyframeEffectReadOnly(
18 targetRO, { opacity: [0, 0.9] }, 1000);
19 var animRO = targetRO.animate(null);
20 animRO.effect = effectRO;
21
22 return Promise.all([anim.ready, animRO.ready]).then(function() {
23 assert_true(internals.isCompositedAnimation(anim),
24 "Opacity animation with KeyframeEffect should be composited");
25 assert_true(internals.isCompositedAnimation(animRO),
26 "Opacity animation with KeyframeEffectReadOnly should be"
27 + " composited");
28 });
29 }, "Using KeyframeEffect or KeyframeEffectReadOnly should not change whether an"
30 + " animation is composited");
31
32 </script>
33 </body>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698