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

Unified Diff: LayoutTests/animations/resources/composited-animations-data/rotate-zero-degrees.js

Issue 1270303002: Composited Animations: Introduce pixel-ref layout tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@disable
Patch Set: Use CSS styles instead of custom flags. Created 5 years, 3 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/resources/composited-animations-data/rotate-zero-degrees.js
diff --git a/LayoutTests/animations/resources/composited-animations-data/rotate-zero-degrees.js b/LayoutTests/animations/resources/composited-animations-data/rotate-zero-degrees.js
new file mode 100644
index 0000000000000000000000000000000000000000..74a47305c7a81bc2d21eada0f24572b673fdcffc
--- /dev/null
+++ b/LayoutTests/animations/resources/composited-animations-data/rotate-zero-degrees.js
@@ -0,0 +1,72 @@
+var animateRotateNoFromAxis = {
+ keyframes: [
+ { rotate: '0deg' },
+ { rotate: '90deg 0 1 0' },
+ ],
+ style: `background: magenta; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+}
+
+var animateRotateNoToAxis = {
+ keyframes: [
+ { rotate: '0deg 1 0 0' },
+ { rotate: '90deg' },
+ ],
+ style: `background: yellow; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+}
+
+var animateRotateFromZeroUnder360 = {
+ keyframes: [
+ { rotate: '0deg 1 0 0' },
+ { rotate: '90deg 0 1 0' },
+ ],
+ style: `background: cyan; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+};
+
+var animateRotateToZeroUnder360 = {
+ keyframes: [
+ { rotate: '90deg 0 1 0' },
+ { rotate: '0deg 1 0 0' },
+ ],
+ style: `background: indigo; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+};
+
+var animateRotateFromZero = {
+ keyframes: [
+ { rotate: '0deg 1 0 0' },
+ { rotate: '450deg 0 1 0' },
+ ],
+ style: `background: green; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+};
+
+var animateRotateToZero = {
+ keyframes: [
+ { rotate: '450deg 0 1 0' },
+ { rotate: '0deg 1 0 0' },
+ ],
+ style: `background: red; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+}
+
+var animateRotateFromAndToZero = {
+ keyframes: [
+ { rotate: '0deg 0 1 0' },
+ { rotate: '0deg 1 0 0' },
+ ],
+ style: `background: blue; margin: 5px;`,
+ samples: getLinearSamples(20, 0, 1)
+}
+
+var rotateZeroDegreesTests = [
+ animateRotateNoFromAxis,
+ animateRotateNoToAxis,
+ animateRotateFromZeroUnder360,
+ animateRotateToZeroUnder360,
+ animateRotateFromZero,
+ animateRotateToZero,
+ animateRotateFromAndToZero,
+];

Powered by Google App Engine
This is Rietveld 408576698