Web Inspector: UI performance test for logging 100 messages to the console.
authorloislo@chromium.org <loislo@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 7 Oct 2011 09:33:26 +0000 (09:33 +0000)
committerloislo@chromium.org <loislo@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 7 Oct 2011 09:33:26 +0000 (09:33 +0000)
https://bugs.webkit.org/show_bug.cgi?id=69608

Reviewed by Pavel Feldman.

* inspector/performance/resources/console-append-100-lines.html: Added.

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

LayoutTests/ChangeLog
LayoutTests/inspector/performance/resources/console-append-100-lines.html [new file with mode: 0644]

index e8497be4aee7a69f54b48316204464ce27f8e196..1532ca08115965f2b5070b03318cc2f4aba9f0bc 100644 (file)
@@ -1,3 +1,12 @@
+2011-10-07  Ilya Tikhonovsky  <loislo@chromium.org>
+
+        Web Inspector: UI performance test for logging 100 messages to the console.
+        https://bugs.webkit.org/show_bug.cgi?id=69608
+
+        Reviewed by Pavel Feldman.
+
+        * inspector/performance/resources/console-append-100-lines.html: Added.
+
 2011-10-05  Kent Tamura  <tkent@chromium.org>
 
         Move <input type=file> tests to fast/forms/file/
 2011-10-05  Kent Tamura  <tkent@chromium.org>
 
         Move <input type=file> tests to fast/forms/file/
diff --git a/LayoutTests/inspector/performance/resources/console-append-100-lines.html b/LayoutTests/inspector/performance/resources/console-append-100-lines.html
new file mode 100644 (file)
index 0000000..fbc3bca
--- /dev/null
@@ -0,0 +1,46 @@
+<html>
+<head>
+<script src="../../../http/tests/inspector/inspector-test.js"></script>
+<script src="performance-test.js"></script>
+<script>
+
+function makeConsoleEvents(count)
+{
+    for (var i = 0; i < count; ++i)
+        console.log("Console log: " + i);
+}
+
+function test()
+{
+    WebInspector.showPanel("console");
+
+    function test(timer)
+    {
+        WebInspector.console.clearMessages();
+        InspectorTest.addSniffer(WebInspector.consoleView.promptElement, "scrollIntoView", finish);
+        cookie = timer.start("console-append-100-lines");
+
+        InspectorTest.evaluateInPage("makeConsoleEvents(100)");
+
+        function finish()
+        {
+            timer.finish(cookie);
+            timer.done();
+        }
+    }
+
+    InspectorTest.runPerformanceTest(test, 10000);
+}
+
+if (!window.layoutTestController) {
+    setTimeout(function() {
+        makeConsoleEvents(100);
+    }, 3000);
+}
+
+</script>
+</head>
+
+<body onload="runTest()">
+</body>
+</html>