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

Unified Diff: LayoutTests/animations/empty-keyframe-animation.html

Issue 14556022: Simplify animation testing API (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/animations/empty-keyframe-animation.html
diff --git a/LayoutTests/animations/empty-keyframe-animation.html b/LayoutTests/animations/empty-keyframe-animation.html
new file mode 100644
index 0000000000000000000000000000000000000000..41f293f922f31b4d9c4976052ef49fa2f422161f
--- /dev/null
+++ b/LayoutTests/animations/empty-keyframe-animation.html
@@ -0,0 +1,50 @@
+<!DOCTYPE html>
+<style>
+#test1 {
+ -webkit-animation-fill-mode: forwards;
+ -webkit-animation-duration: 1s;
+ -webkit-animation-name: green;
+}
+#test2 {
+ -webkit-animation-fill-mode: forwards;
+ -webkit-animation-duration: 1s;
+}
+#test3 {
+ -webkit-animation-fill-mode: forwards;
+ -webkit-animation-duration: 1s;
+ -webkit-animation-name: empty;
+}
+@-webkit-keyframes green {
+ from {
+ background-color: white;
+ }
+ to {
+ background-color: green;
+ }
+}
+@-webkit-keyframes empty {
+}
+</style>
+Tests that an animation with no keyframes does not start.
+<div id="result">FAIL - nothing happened</div>
+<div id="test1"></div>
+<div id="test2"></div>
+<div id="test3"></div>
+<script>
+if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+}
+var pass = true;
+test1.addEventListener('webkitAnimationStart', function() {
+ test2.style.webkitAnimationName = 'green';
+});
+test2.addEventListener('webkitAnimationStart', function() {
+ result.innerText = pass ? 'PASS' : 'FAIL';
+ if (window.testRunner)
+ testRunner.notifyDone();
+});
+test3.addEventListener('webkitAnimationStart', function() {
+ pass = false;
+});
+</script>
« no previous file with comments | « LayoutTests/animations/change-one-anim.html ('k') | LayoutTests/animations/empty-keyframe-animation-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698