Use testRunner instead of layoutTestController in performance tests
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 4 Aug 2012 21:12:36 +0000 (21:12 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 4 Aug 2012 21:12:36 +0000 (21:12 +0000)
https://bugs.webkit.org/show_bug.cgi?id=93184

Reviewed by Adam Barth.

* Animation/balls.html:
* Dromaeo/resources/dromaeorunner.js:
* inspector/console-300-lines.html:
* inspector/inspector-startup-time.html:
* inspector/network-append-30-requests.html.broken:
* inspector/show-panel.html.broken:
* resources/runner.js:
(PerfTestRunner.logInfo):
(PerfTestRunner.initAndStartLoop):

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

PerformanceTests/Animation/balls.html
PerformanceTests/ChangeLog
PerformanceTests/Dromaeo/resources/dromaeorunner.js
PerformanceTests/inspector/console-300-lines.html
PerformanceTests/inspector/inspector-startup-time.html
PerformanceTests/inspector/network-append-30-requests.html.broken
PerformanceTests/inspector/show-panel.html.broken
PerformanceTests/resources/runner.js

index da4dfda..6b79f19 100644 (file)
             PerfTestRunner.log("<br>===================================================<br>");
             init();
         }
-        else if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        else if (window.testRunner)
+            testRunner.notifyDone();
     }
     </script>
     <script src="../resources/runner.js"></script>
index 9b903b9..b248650 100644 (file)
@@ -1,3 +1,20 @@
+2012-08-04  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Use testRunner instead of layoutTestController in performance tests
+        https://bugs.webkit.org/show_bug.cgi?id=93184
+
+        Reviewed by Adam Barth.
+
+        * Animation/balls.html:
+        * Dromaeo/resources/dromaeorunner.js:
+        * inspector/console-300-lines.html:
+        * inspector/inspector-startup-time.html:
+        * inspector/network-append-30-requests.html.broken:
+        * inspector/show-panel.html.broken:
+        * resources/runner.js:
+        (PerfTestRunner.logInfo):
+        (PerfTestRunner.initAndStartLoop):
+
 2012-08-02  Arnaud Renevier  <a.renevier@sisa.samsung.com>
 
         TypedArray set method is slow when called with another typed array
index c89ac71..551a722 100644 (file)
@@ -64,8 +64,8 @@
              var scores = DRT.computeScores(data.result);
              PerfTestRunner.printStatistics(scores);
              window.setTimeout(function() {
-                 if (window.layoutTestController)
-                     layoutTestController.notifyDone();
+                 if (window.testRunner)
+                     testRunner.notifyDone();
              }, 0);
          },
 
index a801947..6e54ca3 100644 (file)
@@ -66,7 +66,7 @@ function test()
     InspectorTest.runPerformanceTest(test, 10000);
 }
 
-if (!window.layoutTestController) {
+if (!window.testRunner) {
     setTimeout(function() {
         makeConsoleEvents(300);
     }, 3000);
index c0fa1bf..43e9d0b 100644 (file)
@@ -7,7 +7,7 @@
 
 function onload()
 {
-    layoutTestController.waitUntilDone();
+    testRunner.waitUntilDone();
     times = [];
     startTime = Date.now();
     testStartTime = startTime;
@@ -18,13 +18,13 @@ function inspectorIsReady()
 {
     times.push(Date.now() - startTime);
     if (Date.now() - testStartTime > 20000) {
-        layoutTestController.evaluateInWebInspector(2, "InspectorTest.dumpTestStats('inspector-startup-time', 'time', " + JSON.stringify(times) + ", 'ms')")
-        layoutTestController.evaluateInWebInspector(3, "(InspectorTest.completeTest())")
+        testRunner.evaluateInWebInspector(2, "InspectorTest.dumpTestStats('inspector-startup-time', 'time', " + JSON.stringify(times) + ", 'ms')")
+        testRunner.evaluateInWebInspector(3, "(InspectorTest.completeTest())")
         return;
     }
-    layoutTestController.closeWebInspector();
+    testRunner.closeWebInspector();
     startTime = Date.now();
-    layoutTestController.showWebInspector();
+    testRunner.showWebInspector();
     runTest();
 }
 
index 4c626bd..357cbc9 100644 (file)
@@ -38,7 +38,7 @@ function test()
     InspectorTest.runPerformanceTest(test, 15000);
 }
 
-if (!window.layoutTestController) {
+if (!window.testRunner) {
     setTimeout(function() {
         makeXHRRequests(30);
     }, 3000);
index c2a4d7a..b59f062 100644 (file)
@@ -42,7 +42,7 @@ function test()
         for (var panelName in WebInspector.panels) {
             var timerCookie = timer.start("show-panel-" + panelName);
             WebInspector.showPanel(panelName);
-            InspectorTest.evaluateInPage("layoutTestController.display();");
+            InspectorTest.evaluateInPage("testRunner.display();");
             timer.finish(timerCookie);
         }
         timer.done("panel-switch");
index 251a7c4..9b27f9a 100644 (file)
@@ -42,7 +42,7 @@ PerfTestRunner.info = function (text) {
 }
 
 PerfTestRunner.logInfo = function (text) {
-    if (!window.layoutTestController)
+    if (!window.testRunner)
         this.log(text);
 }
 
@@ -131,8 +131,8 @@ PerfTestRunner._runLoop = function () {
             logLines.forEach(function(text) { self.log(text); });
         }
         this._doneFunction();
-        if (window.layoutTestController)
-            layoutTestController.notifyDone();
+        if (window.testRunner)
+            testRunner.notifyDone();
     }
 }
 
@@ -172,7 +172,7 @@ PerfTestRunner.initAndStartLoop = function() {
     this._completedRuns = -1;
     this.customRunFunction = null;
     this._results = [];
-    this._logLines = window.layoutTestController ? [] : null;
+    this._logLines = window.testRunner ? [] : null;
     this.log("Running " + this._runCount + " times");
     this._runLoop();
 }
@@ -227,7 +227,7 @@ PerfTestRunner._perSecondRunnerIterator = function (callsPerIteration) {
     return Date.now() - startTime;
 }
 
-if (window.layoutTestController) {
-    layoutTestController.waitUntilDone();
-    layoutTestController.dumpAsText();
+if (window.testRunner) {
+    testRunner.waitUntilDone();
+    testRunner.dumpAsText();
 }