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

Unified Diff: third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-empty-transition-cancel.html

Issue 1433623002: Devtools Animations: Don't wait for empty transitions to start (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 1 month 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: third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-empty-transition-cancel.html
diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-empty-transition-cancel.html b/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-empty-transition-cancel.html
new file mode 100644
index 0000000000000000000000000000000000000000..8be61a2e2da586e7c6f6b0fd3a1bfaf55f660265
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/inspector-protocol/animation/animation-empty-transition-cancel.html
@@ -0,0 +1,41 @@
+<html>
+<head>
+<script type="text/javascript" src="../../http/tests/inspector-protocol/inspector-protocol-test.js"></script>
+<script>
+
+function triggerEmptyTransition()
+{
+ node.offsetTop;
+ node.style.transition = "1s";
+ node.offsetTop;
+ node.style.width = "200px";
+ node.offsetTop;
+ node.style.transition = "";
+ node.offsetTop;
+}
+
+function test()
+{
+ InspectorTest.eventHandler["Animation.animationCreated"] = onCreated;
+ InspectorTest.eventHandler["Animation.animationCanceled"] = onCanceled;
+ InspectorTest.sendCommand("Animation.enable", {});
+ InspectorTest.evaluateInPage("triggerEmptyTransition()", function() {});
+
+ function onCreated()
+ {
+ InspectorTest.log("Animation created");
+ }
+
+ function onCanceled()
+ {
+ InspectorTest.log("Animation canceled");
+ InspectorTest.completeTest();
+ }
+}
+
+</script>
+</head>
+<body onload="runTest()">
+ <div id="node" style="background-color: red; width: 100px"></div>
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698