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

Unified Diff: LayoutTests/animations/interpolation/svg-cy-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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/animations/interpolation/svg-cy-interpolation.html
diff --git a/LayoutTests/animations/interpolation/svg-cy-interpolation.html b/LayoutTests/animations/interpolation/svg-cy-interpolation.html
index f5e569e3fc31d8e399637b1999f0ff34d03f324b..83c06f772d95de2d685919f59f226ac5bffbe4db 100644
--- a/LayoutTests/animations/interpolation/svg-cy-interpolation.html
+++ b/LayoutTests/animations/interpolation/svg-cy-interpolation.html
@@ -1,29 +1,88 @@
<!DOCTYPE html>
<meta charset="UTF-8">
<style>
-svg {
+.container {
+ display: inline-block;
+}
+.parent {
cy: 100px;
}
.target {
- stroke: black;
font-size: 16px;
+ cy: 50px;
}
.expected {
- stroke: green;
+ fill: green;
}
</style>
<body>
<template id="target-template">
- <svg height="200" width="10">
- <circle cx="50%" cy="50%" r="25%" class="target">
+ <svg height="200" width="20">
+ <circle cx="50%" cy="50%" r="10" class="target">
</svg>
</template>
<script src="resources/interpolation-test.js"></script>
<script>
assertInterpolation({
property: 'cy',
+ from: '',
+ to: '20px',
+}, [
+ {at: -0.25, is: '57.5px'},
+ {at: 0, is: '50px'},
+ {at: 0.25, is: '42.5px'},
+ {at: 0.5, is: '35px'},
+ {at: 0.75, is: '27.5px'},
+ {at: 1, is: '20px'},
+ {at: 1.25, is: '12.5px'},
+]);
+
+assertInterpolation({
+ property: 'cy',
+ from: 'initial',
+ to: '20px',
+}, [
+ {at: -0.25, is: '-5px'},
+ {at: 0, is: '0px'},
+ {at: 0.25, is: '5px'},
+ {at: 0.5, is: '10px'},
+ {at: 0.75, is: '15px'},
+ {at: 1, is: '20px'},
+ {at: 1.25, is: '25px'},
+]);
+
+assertInterpolation({
+ property: 'cy',
+ from: 'inherit',
+ to: '20px',
+}, [
+ {at: -0.25, is: '120px'},
+ {at: 0, is: '100px'},
+ {at: 0.25, is: '80px'},
+ {at: 0.5, is: '60px'},
+ {at: 0.75, is: '40px'},
+ {at: 1, is: '20px'},
+ {at: 1.25, is: '0px'},
+]);
+
+assertInterpolation({
+ property: 'cy',
+ from: 'unset',
+ to: '20px',
+}, [
+ {at: -0.25, is: '-5px'},
+ {at: 0, is: '0px'},
+ {at: 0.25, is: '5px'},
+ {at: 0.5, is: '10px'},
+ {at: 0.75, is: '15px'},
+ {at: 1, is: '20px'},
+ {at: 1.25, is: '25px'},
+]);
+
+assertInterpolation({
+ property: 'cy',
from: '-10px',
- to: '10px'
+ to: '10px',
}, [
{at: -0.25, is: '-15px'},
{at: 0, is: '-10px'},
@@ -36,7 +95,7 @@ assertInterpolation({
assertInterpolation({
property: 'cy',
from: '-20px',
- to: '30em'
+ to: '30em',
}, [
{at: -0.25, is: '-145px'},
{at: 0, is: '-20px'},
@@ -49,7 +108,7 @@ assertInterpolation({
assertInterpolation({
property: 'cy',
from: 'inherit',
- to: '140px'
+ to: '140px',
}, [
{at: -0.25, is: '90px'},
{at: 0, is: '100px'},
@@ -62,7 +121,7 @@ assertInterpolation({
assertInterpolation({
property: 'cy',
from: '-10',
- to: '10'
+ to: '10',
}, [
{at: -0.25, is: '-15'},
{at: 0, is: '-10'},

Powered by Google App Engine
This is Rietveld 408576698