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

Side by Side Diff: LayoutTests/animations/empty-keyframe-animation.html

Issue 14556022: Simplify animation testing API (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add new tests. Created 7 years, 7 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <style>
3 #test1 {
4 -webkit-animation-fill-mode: forwards;
5 -webkit-animation-duration: 1s;
6 -webkit-animation-name: green;
7 }
8 #test2 {
9 -webkit-animation-fill-mode: forwards;
10 -webkit-animation-duration: 1s;
11 }
12 #test3 {
13 -webkit-animation-fill-mode: forwards;
14 -webkit-animation-duration: 1s;
15 -webkit-animation-name: empty;
16 }
17 @-webkit-keyframes green {
18 from {
19 background-color: white;
20 }
21 to {
22 background-color: green;
23 }
24 }
25 @-webkit-keyframes empty {
26 }
27 </style>
28 Tests that an animation with no keyframes does not start.
29 <div id="result">FAIL - nothing happened</div>
30 <div id="test1"></div>
31 <div id="test2"></div>
32 <div id="test3"></div>
33 <script>
34 if (window.testRunner) {
35 testRunner.dumpAsText();
Steve Block 2013/05/06 01:49:06 I know there are lots of places where this isn't f
dstockwell 2013/05/06 04:01:00 Done.
36 testRunner.waitUntilDone();
37 }
38 var pass = true;
39 test1.addEventListener('webkitAnimationStart', function() {
40 test2.style.webkitAnimationName = 'green';
41 });
42 test2.addEventListener('webkitAnimationStart', function() {
43 result.innerText = pass ? 'PASS' : 'FAIL';
44 if (window.testRunner)
45 testRunner.notifyDone();
46 });
47 test3.addEventListener('webkitAnimationStart', function() {
48 pass = false;
49 });
50 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698