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

Side by Side Diff: LayoutTests/animations/interpolation/webkit-clip-path-interpolation.html

Issue 1265873002: Add test coverage for interpolations using CSS wide keywords and neutral keyframes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 5 years, 4 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
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <meta charset="UTF-8"> 2 <meta charset="UTF-8">
3 <style> 3 <style>
4 .parent {
5 -webkit-clip-path: inset(10px);
6 padding: 10px;
7 }
4 .target { 8 .target {
9 display: inline-block;
5 width: 100px; 10 width: 100px;
6 height: 100px; 11 height: 100px;
12 background-color: black;
13 -webkit-clip-path: inset(10px);
7 } 14 }
8 .actual { 15 .expected {
9 background-color: green; 16 background-color: green;
10 display: inline-block;
11 }
12
13 .expected {
14 background-color: black;
15 display: inline-block;
16 } 17 }
17 </style> 18 </style>
18 <body> 19 <body>
19 <script src="resources/interpolation-test.js"></script> 20 <script src="resources/interpolation-test.js"></script>
20 <script> 21 <script>
21 assertInterpolation({ 22 assertInterpolation({
22 property: '-webkit-clip-path', 23 property: '-webkit-clip-path',
24 from: '',
25 to: 'inset(20px)',
26 }, [
27 {at: -0.3, is: 'inset(7px)'},
28 {at: 0, is: 'inset(10px)'},
29 {at: 0.3, is: 'inset(13px)'},
30 {at: 0.6, is: 'inset(16px)'},
31 {at: 1, is: 'inset(20px)'},
32 {at: 1.5, is: 'inset(25px)'},
33 ]);
34
35 assertNoInterpolation({
36 property: '-webkit-clip-path',
37 from: 'initial',
38 to: 'inset(20px)',
39 });
40
41 assertInterpolation({
42 property: '-webkit-clip-path',
43 from: 'inherit',
44 to: 'inset(20px)',
45 }, [
46 {at: -0.3, is: 'inset(7px)'},
47 {at: 0, is: 'inset(10px)'},
48 {at: 0.3, is: 'inset(13px)'},
49 {at: 0.6, is: 'inset(16px)'},
50 {at: 1, is: 'inset(20px)'},
51 {at: 1.5, is: 'inset(25px)'},
52 ]);
53
54 assertNoInterpolation({
55 property: '-webkit-clip-path',
56 from: 'unset',
57 to: 'inset(20px)',
58 });
59
60 assertInterpolation({
61 property: '-webkit-clip-path',
23 from: 'circle(10px at 25px 75px)', 62 from: 'circle(10px at 25px 75px)',
24 to: 'circle(50px at 50px 50px)' 63 to: 'circle(50px at 50px 50px)'
25 }, [ 64 }, [
26 {at: -0.3, is: 'circle(0px at 17.5px 82.5px)'}, // radius can't be negative 65 {at: -0.3, is: 'circle(0px at 17.5px 82.5px)'}, // radius can't be negative
27 {at: 0, is: 'circle(10px at 25px 75px)'}, 66 {at: 0, is: 'circle(10px at 25px 75px)'},
28 {at: 0.3, is: 'circle(22px at 32.5px 67.5px)'}, 67 {at: 0.3, is: 'circle(22px at 32.5px 67.5px)'},
29 {at: 0.6, is: 'circle(34px at 40px 60px)'}, 68 {at: 0.6, is: 'circle(34px at 40px 60px)'},
30 {at: 1, is: 'circle(50px at 50px 50px)'}, 69 {at: 1, is: 'circle(50px at 50px 50px)'},
31 {at: 1.5, is: 'circle(70px at 62.5px 37.5px)'} 70 {at: 1.5, is: 'circle(70px at 62.5px 37.5px)'}
32 ]); 71 ]);
(...skipping 12 matching lines...) Expand all
45 {at: -0.3, is: 'inset(-6%)'}, 84 {at: -0.3, is: 'inset(-6%)'},
46 {at: 0, is: 'inset(0%)'}, 85 {at: 0, is: 'inset(0%)'},
47 {at: 0.3, is: 'inset(6%)'}, 86 {at: 0.3, is: 'inset(6%)'},
48 {at: 0.6, is: 'inset(12%)'}, 87 {at: 0.6, is: 'inset(12%)'},
49 {at: 1, is: 'inset(20%)'}, 88 {at: 1, is: 'inset(20%)'},
50 {at: 1.5, is: 'inset(30%)'}, 89 {at: 1.5, is: 'inset(30%)'},
51 ]); 90 ]);
52 91
53 </script> 92 </script>
54 </body> 93 </body>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698