Use testRunner instead of layoutTestController in animations tests
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Jun 2012 17:22:07 +0000 (17:22 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Jun 2012 17:22:07 +0000 (17:22 +0000)
https://bugs.webkit.org/show_bug.cgi?id=88757

Reviewed by Tony Chang.

* animations/3d/change-transform-in-end-event.html:
* animations/3d/replace-filling-transform.html:
* animations/3d/state-at-end-event-transform.html:
* animations/3d/transform-origin-vs-functions.html:
* animations/animation-add-events-in-handler.html:
* animations/animation-border-overflow.html:
* animations/animation-controller-drt-api.html:
* animations/animation-direction-reverse-fill-mode-hardware.html:
* animations/animation-direction-reverse-fill-mode.html:
* animations/animation-drt-api-multiple-keyframes.html:
* animations/animation-drt-api.html:
* animations/animation-end-event-destroy-renderer.html:
* animations/animation-end-event-short-iterations.html:
* animations/animation-hit-test-transform.html:
* animations/animation-hit-test.html:
* animations/animation-iteration-event-destroy-renderer.html:
* animations/animation-matrix-negative-scale-unmatrix.html:
* animations/animation-on-inline-crash.html:
* animations/animation-shorthand-overriding.html:
* animations/animation-shorthand-removed.html:
* animations/animation-shorthand.html:
* animations/animation-start-event-destroy-renderer.html:
* animations/animation-welcome-safari.html:
* animations/body-removal-crash.html:
* animations/change-keyframes-name.html:
* animations/change-transform-style-during-animation.html:
* animations/combo-transform-translate+scale.html:
* animations/empty-keyframes.html:
* animations/fill-mode-forwards.html:
* animations/fill-mode-iteration-count-non-integer.html:
* animations/fill-mode-missing-from-to-keyframes.html:
* animations/fill-mode-multiple-keyframes.html:
* animations/fill-mode-removed.html:
* animations/fill-mode-reverse.html:
* animations/fill-mode-transform.html:
* animations/fill-mode.html:
* animations/fill-unset-properties.html:
* animations/font-size-using-ems.html-disabled:
* animations/import-crash.html:
* animations/keyframe-timing-functions-transform.html:
* animations/keyframe-timing-functions2.html:
* animations/keyframes-iteration-count-non-integer.html:
* animations/longhand-timing-function.html:
* animations/missing-from-to-transforms.html:
* animations/missing-from-to.html:
* animations/pause-crash.html:
* animations/resources/animation-test-helpers.js:
(checkExpectedValue):
(endTest):
* animations/state-at-end-event.html:
* animations/suspend-resume-animation-events.html:
* animations/suspend-transform-animation.html:
* animations/transition-and-animation-3.html:
* animations/unanimated-style.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@119985 268f45cc-cd09-0410-ab3c-d52691b4dbfc

53 files changed:
LayoutTests/ChangeLog
LayoutTests/animations/3d/change-transform-in-end-event.html
LayoutTests/animations/3d/replace-filling-transform.html
LayoutTests/animations/3d/state-at-end-event-transform.html
LayoutTests/animations/3d/transform-origin-vs-functions.html
LayoutTests/animations/animation-add-events-in-handler.html
LayoutTests/animations/animation-border-overflow.html
LayoutTests/animations/animation-controller-drt-api.html
LayoutTests/animations/animation-direction-reverse-fill-mode-hardware.html
LayoutTests/animations/animation-direction-reverse-fill-mode.html
LayoutTests/animations/animation-drt-api-multiple-keyframes.html
LayoutTests/animations/animation-drt-api.html
LayoutTests/animations/animation-end-event-destroy-renderer.html
LayoutTests/animations/animation-end-event-short-iterations.html
LayoutTests/animations/animation-hit-test-transform.html
LayoutTests/animations/animation-hit-test.html
LayoutTests/animations/animation-iteration-event-destroy-renderer.html
LayoutTests/animations/animation-matrix-negative-scale-unmatrix.html
LayoutTests/animations/animation-on-inline-crash.html
LayoutTests/animations/animation-shorthand-overriding.html
LayoutTests/animations/animation-shorthand-removed.html
LayoutTests/animations/animation-shorthand.html
LayoutTests/animations/animation-start-event-destroy-renderer.html
LayoutTests/animations/animation-welcome-safari.html
LayoutTests/animations/body-removal-crash.html
LayoutTests/animations/change-keyframes-name.html
LayoutTests/animations/change-transform-style-during-animation.html
LayoutTests/animations/combo-transform-translate+scale.html
LayoutTests/animations/empty-keyframes.html
LayoutTests/animations/fill-mode-forwards.html
LayoutTests/animations/fill-mode-iteration-count-non-integer.html
LayoutTests/animations/fill-mode-missing-from-to-keyframes.html
LayoutTests/animations/fill-mode-multiple-keyframes.html
LayoutTests/animations/fill-mode-removed.html
LayoutTests/animations/fill-mode-reverse.html
LayoutTests/animations/fill-mode-transform.html
LayoutTests/animations/fill-mode.html
LayoutTests/animations/fill-unset-properties.html
LayoutTests/animations/font-size-using-ems.html-disabled
LayoutTests/animations/import-crash.html
LayoutTests/animations/keyframe-timing-functions-transform.html
LayoutTests/animations/keyframe-timing-functions2.html
LayoutTests/animations/keyframes-iteration-count-non-integer.html
LayoutTests/animations/longhand-timing-function.html
LayoutTests/animations/missing-from-to-transforms.html
LayoutTests/animations/missing-from-to.html
LayoutTests/animations/pause-crash.html
LayoutTests/animations/resources/animation-test-helpers.js
LayoutTests/animations/state-at-end-event.html
LayoutTests/animations/suspend-resume-animation-events.html
LayoutTests/animations/suspend-transform-animation.html
LayoutTests/animations/transition-and-animation-3.html
LayoutTests/animations/unanimated-style.html

index 0b0750f..af237ee 100644 (file)
@@ -1,3 +1,65 @@
+2012-06-11  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Use testRunner instead of layoutTestController in animations tests
+        https://bugs.webkit.org/show_bug.cgi?id=88757
+
+        Reviewed by Tony Chang.
+
+        * animations/3d/change-transform-in-end-event.html:
+        * animations/3d/replace-filling-transform.html:
+        * animations/3d/state-at-end-event-transform.html:
+        * animations/3d/transform-origin-vs-functions.html:
+        * animations/animation-add-events-in-handler.html:
+        * animations/animation-border-overflow.html:
+        * animations/animation-controller-drt-api.html:
+        * animations/animation-direction-reverse-fill-mode-hardware.html:
+        * animations/animation-direction-reverse-fill-mode.html:
+        * animations/animation-drt-api-multiple-keyframes.html:
+        * animations/animation-drt-api.html:
+        * animations/animation-end-event-destroy-renderer.html:
+        * animations/animation-end-event-short-iterations.html:
+        * animations/animation-hit-test-transform.html:
+        * animations/animation-hit-test.html:
+        * animations/animation-iteration-event-destroy-renderer.html:
+        * animations/animation-matrix-negative-scale-unmatrix.html:
+        * animations/animation-on-inline-crash.html:
+        * animations/animation-shorthand-overriding.html:
+        * animations/animation-shorthand-removed.html:
+        * animations/animation-shorthand.html:
+        * animations/animation-start-event-destroy-renderer.html:
+        * animations/animation-welcome-safari.html:
+        * animations/body-removal-crash.html:
+        * animations/change-keyframes-name.html:
+        * animations/change-transform-style-during-animation.html:
+        * animations/combo-transform-translate+scale.html:
+        * animations/empty-keyframes.html:
+        * animations/fill-mode-forwards.html:
+        * animations/fill-mode-iteration-count-non-integer.html:
+        * animations/fill-mode-missing-from-to-keyframes.html:
+        * animations/fill-mode-multiple-keyframes.html:
+        * animations/fill-mode-removed.html:
+        * animations/fill-mode-reverse.html:
+        * animations/fill-mode-transform.html:
+        * animations/fill-mode.html:
+        * animations/fill-unset-properties.html:
+        * animations/font-size-using-ems.html-disabled:
+        * animations/import-crash.html:
+        * animations/keyframe-timing-functions-transform.html:
+        * animations/keyframe-timing-functions2.html:
+        * animations/keyframes-iteration-count-non-integer.html:
+        * animations/longhand-timing-function.html:
+        * animations/missing-from-to-transforms.html:
+        * animations/missing-from-to.html:
+        * animations/pause-crash.html:
+        * animations/resources/animation-test-helpers.js:
+        (checkExpectedValue):
+        (endTest):
+        * animations/state-at-end-event.html:
+        * animations/suspend-resume-animation-events.html:
+        * animations/suspend-transform-animation.html:
+        * animations/transition-and-animation-3.html:
+        * animations/unanimated-style.html:
+
 2012-06-11  David Barr  <davidbarr@chromium.org>
 
         Add css3-images image-resolution (dppx only)
index 8adea4a..5dce399 100644 (file)
     function testEnded()
     {
       document.getElementById('tester').style.webkitTransform = 'translateX(150px)';
-      if (window.layoutTestController)
-        layoutTestController.notifyDone();
+      if (window.testRunner)
+        testRunner.notifyDone();
     }
     
     function startTest()
     {
-      if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+      if (window.testRunner)
+        testRunner.waitUntilDone();
 
       document.getElementById('tester').addEventListener('webkitAnimationEnd', testEnded, false);
       document.getElementById('container').className = 'moved';
index 6525f6e..09ec341 100644 (file)
@@ -56,8 +56,8 @@
             else
                 result.innerHTML = "FAIL - final state was " + computedValue + " expected " + expectedValue;
 
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }
 
         function swapAnim()
@@ -76,9 +76,9 @@
             document.addEventListener("webkitAnimationEnd", swapAnim, false);
         }
         
-        if (window.layoutTestController) {
-            layoutTestController.dumpAsText(true);
-            layoutTestController.waitUntilDone();
+        if (window.testRunner) {
+            testRunner.dumpAsText(true);
+            testRunner.waitUntilDone();
         }
 
         window.addEventListener("load", setup, false);
index f1e5b6b..63e80e6 100644 (file)
 
     function testEnded()
     {
-      if (window.layoutTestController)
-        layoutTestController.notifyDone();
+      if (window.testRunner)
+        testRunner.notifyDone();
     }
     
     function startTest()
     {
-      if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+      if (window.testRunner)
+        testRunner.waitUntilDone();
 
       document.getElementById('tester').addEventListener('webkitAnimationEnd', testEnded, false);
       document.getElementById('container').className = 'moved';
index 76247d0..d03f9c3 100644 (file)
@@ -55,9 +55,9 @@
     </style>
     
     <script type="text/javascript" charset="utf-8">
-      if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+      if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
       }
 
       resultEntries = [];
@@ -99,8 +99,8 @@
           if (numSnapshots == 2) {
               resultEntries.sort();
               document.getElementById('result').innerHTML = resultEntries.join("");
-              if (window.layoutTestController)
-                  layoutTestController.notifyDone();
+              if (window.testRunner)
+                  testRunner.notifyDone();
           }
       }
       
index a2c14eb..812785f 100644 (file)
@@ -1,7 +1,7 @@
 <script>
-if (window.layoutTestController) {
-    layoutTestController.dumpAsText();
-    layoutTestController.waitUntilDone();
+if (window.testRunner) {
+    testRunner.dumpAsText();
+    testRunner.waitUntilDone();
 }
 
 function touchElement(evt) {
@@ -10,8 +10,8 @@ function touchElement(evt) {
     total++;
     if (total == 500) {
         document.getElementById("results").innerHTML = "PASS: Adding animation events in the handler did not crash.";
-        if (window.layoutTestController)
-          layoutTestController.notifyDone();
+        if (window.testRunner)
+          testRunner.notifyDone();
     }
 }
 
index d8cd3ed..c571659 100644 (file)
@@ -19,8 +19,8 @@
 </style>
     <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
     <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
 
     const expectedValues = [
       // [animation-name, time, element-id, property, expected-value, tolerance]
index 5d4878d..d0f0186 100644 (file)
@@ -50,7 +50,7 @@
    
     function sample0() {
       var expected = 4;
-      var current = layoutTestController.numberOfActiveAnimations();
+      var current = testRunner.numberOfActiveAnimations();
       if (current == expected)
         document.getElementById('result0').innerHTML = "Number of active animations at 0s is (" + current + ") as expected";
       else
     
     function sample1() {
       var expected = 4;
-      var current = layoutTestController.numberOfActiveAnimations();
+      var current = testRunner.numberOfActiveAnimations();
       if (current == expected)
         document.getElementById('result1').innerHTML = "Number of active animations at 1s is (" + current + ") as expected";
       else
         document.getElementById('result1').innerHTML = "Number of active animations at 1s is (" + current + ") but was expecting (" + expected + ")";
       
-      layoutTestController.notifyDone();
+      testRunner.notifyDone();
     }
     
     function startTest() {
-      if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+      if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
         
         var target = document.getElementById('target');
         target.style.top = '200px';
index dd32feb..33bcbfa 100644 (file)
@@ -43,9 +43,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -68,8 +68,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
     
     window.onload = function () {
index 7b3c2e1..76fef2d 100644 (file)
@@ -56,9 +56,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -81,8 +81,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index b89388d..e0e093c 100644 (file)
 
    <script src="resources/animation-test-helpers.js"></script>
    <script>
-     if (window.layoutTestController) {
-       layoutTestController.waitUntilDone();
-       layoutTestController.dumpAsText();
+     if (window.testRunner) {
+       testRunner.waitUntilDone();
+       testRunner.dumpAsText();
      }
    
     function animationStarted()
     {
-      if (window.layoutTestController) {
-        var paused = layoutTestController.pauseAnimationAtTimeOnElementWithId("anim", 1, "target");
+      if (window.testRunner) {
+        var paused = testRunner.pauseAnimationAtTimeOnElementWithId("anim", 1, "target");
         var result;
         if (paused)
           result = "PASS: correctly paused animation";
@@ -39,7 +39,7 @@
           result = "FAIL: failed to pause animation";
 
         document.getElementById('results').innerText = result;
-        layoutTestController.notifyDone();
+        testRunner.notifyDone();
       } else
         document.getElementById('results').innerText = "This test requires DRT";
     }
index 0e944ed..876338a 100644 (file)
 
   <script src="resources/animation-test-helpers.js"></script>
   <script>
-    if (window.layoutTestController) {
-      layoutTestController.waitUntilDone();
-      layoutTestController.dumpAsText();
+    if (window.testRunner) {
+      testRunner.waitUntilDone();
+      testRunner.dumpAsText();
     }
 
     function animationStarted()
     {
-      if (window.layoutTestController) {
-        var paused = layoutTestController.pauseAnimationAtTimeOnElementWithId("bounce", 1.0, "target");
+      if (window.testRunner) {
+        var paused = testRunner.pauseAnimationAtTimeOnElementWithId("bounce", 1.0, "target");
         var result = "";
         if (paused)
           result = "PASS: correctly paused animation";
@@ -41,7 +41,7 @@
           result = "FAIL: failed to pause animation";
 
         document.getElementById('results').innerText = result;
-        layoutTestController.notifyDone();
+        testRunner.notifyDone();
       } else
         document.getElementById('results').innerText = "This test requires DRT";
     }
index 5cb41a9..2a6e2e9 100644 (file)
@@ -16,9 +16,9 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     var numDone = 0;
@@ -31,8 +31,8 @@
 
         document.getElementById('results').innerHTML = 'Did not crash, so PASSED';
 
-        if (window.layoutTestController)
-          layoutTestController.notifyDone();
+        if (window.testRunner)
+          testRunner.notifyDone();
       }
     }
 
index 483e5b6..e84f4d5 100644 (file)
     }
   </style>
   <script>
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
   
     onload = function()
     {
         document.addEventListener('webkitAnimationEnd', function() {
             document.getElementById('result').innerHTML = 'PASS: got webkitAnimationEnd event';      
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }, false);
         
         // Animation begins once we append the DOM node to the document.
index d3dd980..26baad0 100644 (file)
      
         function doTest()
         {
-            if (window.layoutTestController) {
-                if (!layoutTestController.pauseAnimationAtTimeOnElementWithId("anim", 2.0, "target"))
+            if (window.testRunner) {
+                if (!testRunner.pauseAnimationAtTimeOnElementWithId("anim", 2.0, "target"))
                     throw("Transition is not running");
         
                 checkResults();
-                layoutTestController.notifyDone();
+                testRunner.notifyDone();
             }
             else {
                 window.setTimeout("checkResults()", 2000);
@@ -67,9 +67,9 @@
     
         function startTest()
         {
-            if (window.layoutTestController) {
-                layoutTestController.dumpAsText();
-                layoutTestController.waitUntilDone();
+            if (window.testRunner) {
+                testRunner.dumpAsText();
+                testRunner.waitUntilDone();
             }
       
             document.getElementById("target").style.webkitAnimationName = "anim";
index 6220006..b0913bd 100644 (file)
      
         function doTest()
         {
-            if (window.layoutTestController) {
-                if (!layoutTestController.pauseAnimationAtTimeOnElementWithId("anim", 2.0, "target"))
+            if (window.testRunner) {
+                if (!testRunner.pauseAnimationAtTimeOnElementWithId("anim", 2.0, "target"))
                     throw("Transition is not running");
         
                 checkResults();
-                layoutTestController.notifyDone();
+                testRunner.notifyDone();
             }
             else {
                 window.setTimeout("checkResults()", 2000);
@@ -67,9 +67,9 @@
     
         function startTest()
         {
-            if (window.layoutTestController) {
-                layoutTestController.dumpAsText();
-                layoutTestController.waitUntilDone();
+            if (window.testRunner) {
+                testRunner.dumpAsText();
+                testRunner.waitUntilDone();
             }
       
             document.getElementById("target").style.webkitAnimationName = "anim";
index d7074d5..9a05f30 100644 (file)
@@ -17,9 +17,9 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     var numDone = 0;
@@ -32,8 +32,8 @@
 
         document.getElementById('results').innerHTML = 'Did not crash, so PASSED';
 
-        if (window.layoutTestController)
-          layoutTestController.notifyDone();
+        if (window.testRunner)
+          testRunner.notifyDone();
       }
     }
 
index 4986b3b..02f672a 100644 (file)
@@ -22,9 +22,9 @@
             }
         </style>
         <script type="text/javascript" charset="utf-8">
-            if (window.layoutTestController) {
-                layoutTestController.dumpAsText();
-                layoutTestController.waitUntilDone();
+            if (window.testRunner) {
+                testRunner.dumpAsText();
+                testRunner.waitUntilDone();
             }
 
             result = "PASS";
@@ -39,8 +39,8 @@
                     result = "FAIL(scaleY was positive, expected to be negative)";
 
                 document.getElementById('result').innerHTML = result;
-                if (window.layoutTestController)
-                    layoutTestController.notifyDone();
+                if (window.testRunner)
+                    testRunner.notifyDone();
             }
 
             function startAnimation()
index ef10914..0db2eab 100644 (file)
@@ -9,16 +9,16 @@
     }
 </style>
 <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
     
     function waitForAnimation()
     {
         window.setTimeout(function() {
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }, 50);
     }
     window.addEventListener('load', waitForAnimation, false);
index a0af5e2..7b27164 100644 (file)
@@ -29,8 +29,8 @@ div > div {
 }
 </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
   
     const kProperties = [
       "webkitAnimationName",
index 15bf968..ed2a2a2 100644 (file)
@@ -11,9 +11,9 @@
 @-webkit-keyframes anim1 { }
 </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     const kProperties = [
@@ -90,8 +90,8 @@
 
       var results = document.getElementById('result');
       results.innerHTML = resultsString;
-      if (window.layoutTestController)
-          layoutTestController.notifyDone();
+      if (window.testRunner)
+          testRunner.notifyDone();
     }
 
     window.addEventListener('load', start, false);
index e8fbdf8..5462f8f 100644 (file)
@@ -41,8 +41,8 @@
 @-webkit-keyframes anim2 { }
 </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
   
     const kProperties = [
       "webkitAnimationName",
index 63b3aa8..d18fe20 100644 (file)
@@ -16,9 +16,9 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     var numDone = 0;
@@ -31,8 +31,8 @@
 
         document.getElementById('results').innerHTML = 'Did not crash, so PASSED';
 
-        if (window.layoutTestController)
-          layoutTestController.notifyDone();
+        if (window.testRunner)
+          testRunner.notifyDone();
       }
     }
 
index 686a908..9fcfb01 100644 (file)
@@ -94,9 +94,9 @@ body.go #blue {
 </style>
 
 <script type="text/javascript" charset="utf-8">
-   if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+   if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     var animationStarted = false;
@@ -116,8 +116,8 @@ body.go #blue {
     }, false);
 
     document.addEventListener("webkitAnimationEnd", function(event) {
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }, false);
 
     window.addEventListener("load", function () {
index 0e104f6..ae02de2 100644 (file)
@@ -39,13 +39,13 @@ function crash() {
 function cleanup() {
   document.getElementById("b").parentNode.insertBefore(element, document.getElementById("b").nextSibling);
   
-  if (window.layoutTestController)
-      layoutTestController.notifyDone();
+  if (window.testRunner)
+      testRunner.notifyDone();
 }
 
-if (window.layoutTestController) {
-    layoutTestController.dumpAsText();
-    layoutTestController.waitUntilDone();
+if (window.testRunner) {
+    testRunner.dumpAsText();
+    testRunner.waitUntilDone();
 }
 
 crash();
index 66dac65..2f3ad52 100644 (file)
     
     function setup()
     {
-        if (window.layoutTestController) {
-          layoutTestController.dumpAsText();
-          layoutTestController.waitUntilDone();
-          if (layoutTestController.pauseAnimationAtTimeOnElementWithId("bar", 0.5, "box"))
+        if (window.testRunner) {
+          testRunner.dumpAsText();
+          testRunner.waitUntilDone();
+          if (testRunner.pauseAnimationAtTimeOnElementWithId("bar", 0.5, "box"))
               document.getElementById("pre-result").innerHTML = "FAIL: animation is running";
           else
               document.getElementById("pre-result").innerHTML = "PASS: animation is not running";
index 09bc980..de7d1e7 100644 (file)
@@ -37,9 +37,9 @@
 
    <script src="resources/animation-test-helpers.js"></script>
    <script>
-     if (window.layoutTestController) {
-       layoutTestController.dumpAsText();
-       layoutTestController.waitUntilDone();
+     if (window.testRunner) {
+       testRunner.dumpAsText();
+       testRunner.waitUntilDone();
      }
 
      function animationDone()
@@ -54,7 +54,7 @@
          result = "FAIL - Computed final position is incorrect. Expected " + expected + ", got " + computed;
        }
        document.getElementById('result').innerHTML = result;
-       layoutTestController.notifyDone();
+       testRunner.notifyDone();
      }
 
      function animationStarted()
index 6a78a31..fbd5073 100644 (file)
@@ -20,9 +20,9 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-      layoutTestController.dumpAsText();
-      layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+      testRunner.dumpAsText();
+      testRunner.waitUntilDone();
     }
     
     result = "";
@@ -51,8 +51,8 @@
         numSnapshots++;
         if (numSnapshots == 2) {
             document.getElementById('result').innerHTML = result || "PASS";
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }
     }
 
index bbe779f..0d914eb 100644 (file)
@@ -18,8 +18,8 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
   </script>
 </head>
 <body>
index 7aae7ec..1e0c876 100644 (file)
@@ -1,9 +1,9 @@
 <html>
 <head>
 <script>
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     var pulsingSquareAnimationEnded = false;
@@ -26,8 +26,8 @@
             else
                 result.innerHTML = "PASS - Test working";
 
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }
     }
 
index cd19adb..f419665 100644 (file)
@@ -61,9 +61,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -88,8 +88,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index 34807f5..81d1e35 100644 (file)
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index b698ac3..1327742 100644 (file)
@@ -76,9 +76,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index 6635464..5ff9793 100644 (file)
@@ -48,9 +48,9 @@
       {id: "d", value: 100}
     ];
   
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
   
     function animationEnded(event) {
@@ -77,8 +77,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
   
     window.onload = function () {
index 6d8f469..c279e72 100644 (file)
@@ -58,9 +58,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -85,8 +85,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index 1af81e0..a9b1227 100644 (file)
@@ -58,9 +58,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -86,8 +86,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
     
     window.onload = function () {
index 6c741a5..233cde1 100644 (file)
@@ -57,9 +57,9 @@
     ];
     var result = "";
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationEnded(event) {
@@ -84,8 +84,8 @@
         }
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 
     window.onload = function () {
index 85036c4..e5a290d 100644 (file)
@@ -22,8 +22,8 @@
 @-webkit-keyframes e { }
 </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
   
     const kExpectedResults = [
       { 'property': 'webkitTransitionDuration', 'value': '2s, 2s, 1s, 1s, 2s' },
index 358e2a3..7cd2e8a 100644 (file)
@@ -28,9 +28,9 @@
     }
     </style>
     <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
     
     result = "PASS";
@@ -61,8 +61,8 @@
         
         window.setTimeout(function() {
             document.getElementById('result').innerHTML = result;
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }, 400);
     }
     
index b4d1f8f..73c86a3 100644 (file)
@@ -20,8 +20,8 @@
     }
     </style>
     <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.dumpAsText();
+    if (window.testRunner)
+        testRunner.dumpAsText();
   </script>
 </head>
 <body>
index e76e069..a25bca3 100644 (file)
@@ -30,9 +30,9 @@
     <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
     <script type="text/javascript" charset="utf-8">
 
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
     
     document.addEventListener("webkitAnimationEnd", function(event){
@@ -43,8 +43,8 @@
             result = "FAIL end of animation";
         document.getElementById('result').innerHTML = result;
 
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }, false);
     
   </script>
index 1710b62..a495c96 100644 (file)
@@ -26,8 +26,8 @@
     </style>
     <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
     <script type="text/javascript" charset="utf-8">
-        if (window.layoutTestController)
-            layoutTestController.waitUntilDone();
+        if (window.testRunner)
+            testRunner.waitUntilDone();
 
           const expectedValues = [
             // [animation-name, time, element-id, property, expected-value, tolerance]
index 0a5c172..2eac9e1 100644 (file)
@@ -89,8 +89,8 @@
     ];
 
     runAnimationTest(expectedValues, function() {
-      if (window.layoutTestController) {
-          if (layoutTestController.pauseAnimationAtTimeOnElementWithId("anim5", 0.1, "box5"))
+      if (window.testRunner) {
+          if (testRunner.pauseAnimationAtTimeOnElementWithId("anim5", 0.1, "box5"))
               result += "FAIL - box5 animation was running<br>";
           else 
               result += "PASS - box5 animation was not running<br>";
index 4ab0900..8fac608 100644 (file)
@@ -88,8 +88,8 @@
     ];
 
     runAnimationTest(expectedValues, function() {
-      if (window.layoutTestController) {
-          if (layoutTestController.pauseAnimationAtTimeOnElementWithId("anim5", 0.1, "box5"))
+      if (window.testRunner) {
+          if (testRunner.pauseAnimationAtTimeOnElementWithId("anim5", 0.1, "box5"))
               result += "FAIL - box5 animation was running<br>";
           else 
               result += "PASS - box5 animation was not running<br>";
index a59dd4f..7de9b73 100644 (file)
@@ -18,9 +18,9 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController) {
-        layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+    if (window.testRunner) {
+        testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
 
     function animationStarted()
@@ -31,8 +31,8 @@
                 document.getElementById('box1').style.webkitAnimationPlayState = "running";
                 setTimeout(function() {
                     document.getElementById('results').innerHTML = 'Did not crash, so PASSED';
-                    if (window.layoutTestController)
-                        layoutTestController.notifyDone();
+                    if (window.testRunner)
+                        testRunner.notifyDone();
                 }, 50);
             }, 50);
         }, 50);
index 7a40a82..42598cc 100644 (file)
@@ -155,12 +155,12 @@ function checkExpectedValue(expected, index)
         }
     }
 
-    if (animationName && hasPauseAnimationAPI && !layoutTestController.pauseAnimationAtTimeOnElementWithId(animationName, time, elementId)) {
+    if (animationName && hasPauseAnimationAPI && !testRunner.pauseAnimationAtTimeOnElementWithId(animationName, time, elementId)) {
         result += "FAIL - animation \"" + animationName + "\" is not running" + "<br>";
         return;
     }
     
-    if (compareElements && !element2Static && animationName && hasPauseAnimationAPI && !layoutTestController.pauseAnimationAtTimeOnElementWithId(animationName, time, elementId2)) {
+    if (compareElements && !element2Static && animationName && hasPauseAnimationAPI && !testRunner.pauseAnimationAtTimeOnElementWithId(animationName, time, elementId2)) {
         result += "FAIL - animation \"" + animationName + "\" is not running" + "<br>";
         return;
     }
@@ -272,8 +272,8 @@ function endTest()
 {
     document.getElementById('result').innerHTML = result;
 
-    if (window.layoutTestController)
-        layoutTestController.notifyDone();
+    if (window.testRunner)
+        testRunner.notifyDone();
 }
 
 function checkExpectedValueCallback(expected, index)
@@ -319,14 +319,14 @@ var hasPauseAnimationAPI;
 
 function runAnimationTest(expected, callback, event, disablePauseAnimationAPI, doPixelTest)
 {
-    hasPauseAnimationAPI = ('layoutTestController' in window) && ('pauseAnimationAtTimeOnElementWithId' in layoutTestController);
+    hasPauseAnimationAPI = ('testRunner' in window) && ('pauseAnimationAtTimeOnElementWithId' in testRunner);
     if (disablePauseAnimationAPI)
         hasPauseAnimationAPI = false;
 
-    if (window.layoutTestController) {
+    if (window.testRunner) {
         if (!doPixelTest)
-            layoutTestController.dumpAsText();
-        layoutTestController.waitUntilDone();
+            testRunner.dumpAsText();
+        testRunner.waitUntilDone();
     }
     
     if (!expected)
index 43ca855..145c198 100644 (file)
    <script type="text/javascript">
     function testEnded()
     {
-      if (window.layoutTestController)
-        layoutTestController.notifyDone();
+      if (window.testRunner)
+        testRunner.notifyDone();
     }
     
     function startTest()
     {
-      if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+      if (window.testRunner)
+        testRunner.waitUntilDone();
 
       document.getElementById('tester').addEventListener('webkitAnimationEnd', testEnded, false);
       document.getElementById('container').className = 'moved';
index c1abe56..9fe864b 100644 (file)
     
     function startTest()
     {
-        if (window.layoutTestController) {
-            layoutTestController.dumpAsText();
-            layoutTestController.waitUntilDone();
+        if (window.testRunner) {
+            testRunner.dumpAsText();
+            testRunner.waitUntilDone();
         }
         
         setTimeout(suspend, 40);
         setTimeout(resume, 100);
         setTimeout(function()
         {
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }, 350);
     }
     
index 6bad2e1..c5b3f72 100644 (file)
@@ -33,8 +33,8 @@
     }
   </style>
   <script type="text/javascript" charset="utf-8">
-    if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+    if (window.testRunner)
+        testRunner.waitUntilDone();
     
     function suspendAndWaitForCompletion()
     {
@@ -42,8 +42,8 @@
             internals.suspendAnimations(document);
 
         window.setTimeout(function() {
-            if (window.layoutTestController)
-                layoutTestController.notifyDone();
+            if (window.testRunner)
+                testRunner.notifyDone();
         }, 250);
     }
     
index 737ea0d..6a19c96 100644 (file)
@@ -38,8 +38,8 @@
     <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
     <script type="text/javascript" charset="utf-8">
 
-    if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+    if (window.testRunner)
+        testRunner.waitUntilDone();
 
       const expectedValues = [
         // [animation-name, time, element-id, property, expected-value, tolerance]
index fbb1b82..ebf5b4b 100644 (file)
@@ -31,8 +31,8 @@
     <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
     <script type="text/javascript" charset="utf-8">
 
-    if (window.layoutTestController)
-        layoutTestController.waitUntilDone();
+    if (window.testRunner)
+        testRunner.waitUntilDone();
 
       const expectedValues = [
         // [animation-name, time, element-id, property, expected-value, tolerance]