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

Side by Side Diff: LayoutTests/web-animations-api/w3c/get-animation-players.html

Issue 650543004: Move timeline get CSS AnimationPlayers W3C test into seperate file. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Make file names more consistent Created 6 years, 2 months 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
« no previous file with comments | « no previous file | LayoutTests/web-animations-api/w3c/get-css-players.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../../resources/testharness.js"></script> 2 <script src="../../resources/testharness.js"></script>
3 <script src="../../resources/testharnessreport.js"></script> 3 <script src="../../resources/testharnessreport.js"></script>
4 <style>
5 @keyframes test {
6 from { opacity: 0; }
7 to { opacity: 1; }
8 }
9 .cssAnimation {
10 animation: test 2s;
11 }
12 </style>
13 <div id='container'> 4 <div id='container'>
14 <div id='element'></div> 5 <div id='element'></div>
15 </div> 6 </div>
16 7
17 <script> 8 <script>
18 9
19 var container = document.getElementById('container'); 10 var container = document.getElementById('container');
20 var element = document.getElementById('element'); 11 var element = document.getElementById('element');
21 12
22 test(function() { 13 test(function() {
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 assert_equals(element.getAnimationPlayers().length, 1); 79 assert_equals(element.getAnimationPlayers().length, 1);
89 assert_equals(element.getAnimationPlayers()[0], player); 80 assert_equals(element.getAnimationPlayers()[0], player);
90 81
91 player.finish(); 82 player.finish();
92 assert_equals(document.timeline.getAnimationPlayers().length, 0); 83 assert_equals(document.timeline.getAnimationPlayers().length, 0);
93 assert_equals(container.getAnimationPlayers().length, 0); 84 assert_equals(container.getAnimationPlayers().length, 0);
94 assert_equals(element.getAnimationPlayers().length, 0); 85 assert_equals(element.getAnimationPlayers().length, 0);
95 86
96 }, 'getAnimationPlayers() with delays'); 87 }, 'getAnimationPlayers() with delays');
97 88
98 async_test(function(t) { 89 </script>
99 assert_equals(document.timeline.getAnimationPlayers().length, 0);
100 assert_equals(container.getAnimationPlayers().length, 0);
101 assert_equals(element.getAnimationPlayers().length, 0);
102
103 element.className = 'cssAnimation';
104 t.step(function() {
105 onload = function () {
106 var players = document.timeline.getAnimationPlayers();
107 assert_equals(players.length, 1);
108 assert_equals(container.getAnimationPlayers().length, 0);
109 assert_equals(element.getAnimationPlayers().length, 1);
110
111 players[0].finish();
112 assert_equals(document.timeline.getAnimationPlayers().length, 0);
113 assert_equals(container.getAnimationPlayers().length, 0);
114 assert_equals(element.getAnimationPlayers().length, 0);
115 t.done();
116 }
117 });
118 }, 'getAnimationPlayers() with cssanimations');
119
120 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/web-animations-api/w3c/get-css-players.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698