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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/tracing/timeline-load-event.html

Issue 2145873002: [DevTools] Split inspector/tracing into subdirectories to speed things up. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months 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 unified diff | Download patch
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/timeline-test.js"></script>
5 <script>
6 function display(callback)
7 {
8 if (window.testRunner)
9 testRunner.setCanOpenWindows(true);
10 var popup = window.open("data:text/html,<b>Hello, world</b>");
11 popup.onload = function()
12 {
13 requestAnimationFrame(testRunner.capturePixelsAsyncThen.bind(testRunner, callback));
14 }
15 }
16
17 function test()
18 {
19 WebInspector.panels.timeline._captureJSProfileSetting.set(false);
20 InspectorTest.startTimeline(function() { InspectorTest.reloadPage(pageReload ed); });
21
22 function pageReloaded()
23 {
24 InspectorTest.invokePageFunctionAsync("display", displayDone);
25 }
26
27 function displayDone()
28 {
29 InspectorTest.stopTimeline(InspectorTest.safeWrap(finish))
30 }
31
32 function finish()
33 {
34 InspectorTest.addResult("Model records:");
35 InspectorTest.printTimelineRecords("MarkDOMContent");
36 InspectorTest.printTimelineRecords("MarkLoad");
37 InspectorTest.addResult("Timestamp records:");
38 InspectorTest.printTimestampRecords("MarkDOMContent");
39 InspectorTest.printTimestampRecords("MarkLoad");
40 InspectorTest.printTimestampRecords("MarkFirstPaint");
41
42 var eventDividers = InspectorTest.timelineModel().eventDividerRecords();
43 for (var i = 1; i < eventDividers.length; ++i)
44 InspectorTest.assertGreaterOrEqual(eventDividers[i], eventDividers[i - 1], "Event divider timestamps should be monotonically non-decreasing");
45
46 InspectorTest.completeTest();
47 }
48 }
49
50 </script>
51 </head>
52
53 <body onload="runTest()">
54 <p>
55 Tests the load event.
56 </p>
57
58 </body>
59 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698