Web Inspector: UI performance: introduce heap size tracking stats.
[WebKit-https.git] / LayoutTests / inspector / performance / resources / network-append-30-requests.html
1 <html>
2 <head>
3 <script src="../../../http/tests/inspector/inspector-test.js"></script>
4 <script src="performance-test.js"></script>
5 <script>
6
7 function makeXHRRequests(count)
8 {
9     for (var i = 0; i < count; ++i) {
10         var xhr = new XMLHttpRequest();
11         xhr.open("GET", document.URL, true);
12         xhr.send();
13     }
14 }
15
16 function test()
17 {
18     WebInspector.showPanel("network");
19
20     function test(timer)
21     {
22         WebInspector.panels.network._networkLogView._reset();
23         var cookie = timer.start("network-append-30-requests");
24         InspectorTest.evaluateInPage("makeXHRRequests(30)");
25         function finish()
26         {
27             timer.finish(cookie);
28             timer.done();
29         }
30         InspectorTest.addSniffer(WebInspector.panels.network._networkLogView, "refresh", finish);
31     }
32     InspectorTest.runPerformanceTest(test, 15000);
33 }
34
35 if (!window.layoutTestController) {
36     setTimeout(function() {
37         makeXHRRequests(30);
38     }, 3000);
39 }
40
41 </script>
42 </head>
43
44 <body onload="runTest()">
45 </body>
46 </html>