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

Unified Diff: LayoutTests/animations/interpolation/opacity-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/opacity-interpolation.html
diff --git a/LayoutTests/animations/interpolation/opacity-interpolation.html b/LayoutTests/animations/interpolation/opacity-interpolation.html
index b09c71fdd7897dd519f04b13d8668ef5eb6e51a4..c990b84e29594e9464ac84b70eeaa8f76ec46eec 100644
--- a/LayoutTests/animations/interpolation/opacity-interpolation.html
+++ b/LayoutTests/animations/interpolation/opacity-interpolation.html
@@ -1,11 +1,15 @@
<!DOCTYPE html>
<meta charset="UTF-8">
<style>
+.parent {
+ opacity: 0.8;
+}
.target {
width: 100px;
height: 100px;
background-color: black;
display: inline-block;
+ opacity: 0.1;
}
.expected {
background-color: green;
@@ -16,6 +20,58 @@
<script>
assertInterpolation({
property: 'opacity',
+ from: '',
+ to: '0.2',
+}, [
+ {at: -0.3, is: '0.07'},
+ {at: 0, is: '0.1'},
+ {at: 0.3, is: '0.13'},
+ {at: 0.6, is: '0.16'},
+ {at: 1, is: '0.2'},
+ {at: 1.5, is: '0.25'},
+]);
+
+assertInterpolation({
+ property: 'opacity',
+ from: 'initial',
+ to: '0.2',
+}, [
+ {at: -0.3, is: '1'},
+ {at: 0, is: '1'},
+ {at: 0.3, is: '0.76'},
+ {at: 0.6, is: '0.52'},
+ {at: 1, is: '0.2'},
+ {at: 1.5, is: '0'},
+]);
+
+assertInterpolation({
+ property: 'opacity',
+ from: 'inherit',
+ to: '0.2',
+}, [
+ {at: -0.3, is: '0.98'},
+ {at: 0, is: '0.8'},
+ {at: 0.3, is: '0.62'},
+ {at: 0.6, is: '0.44'},
+ {at: 1, is: '0.2'},
+ {at: 1.5, is: '0'},
+]);
+
+assertInterpolation({
+ property: 'opacity',
+ from: 'unset',
+ to: '0.2',
+}, [
+ {at: -0.3, is: '1'},
+ {at: 0, is: '1'},
+ {at: 0.3, is: '0.76'},
+ {at: 0.6, is: '0.52'},
+ {at: 1, is: '0.2'},
+ {at: 1.5, is: '0'},
+]);
+
+assertInterpolation({
+ property: 'opacity',
from: '0',
to: '1'
}, [

Powered by Google App Engine
This is Rietveld 408576698