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

Side by Side Diff: LayoutTests/inspector/tracing/timeline-paint.html

Issue 1315373005: DevTools: remove most convenience wrappers from WI.TimelineModel.Record (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 3 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
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script> 3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/timeline-test.js"></script> 4 <script src="../../http/tests/inspector/timeline-test.js"></script>
5 <script> 5 <script>
6 6
7 function display(callback) 7 function display(callback)
8 { 8 {
9 requestAnimationFrame(function() { 9 requestAnimationFrame(function() {
10 document.body.style.backgroundColor = "blue"; 10 document.body.style.backgroundColor = "blue";
(...skipping 22 matching lines...) Expand all
33 InspectorTest.printTimelineRecordProperties(record); 33 InspectorTest.printTimelineRecordProperties(record);
34 else 34 else
35 InspectorTest.addResult("FAIL: no paint record found"); 35 InspectorTest.addResult("FAIL: no paint record found");
36 InspectorTest.invokeAsyncWithTimeline("updateSubframeAndDisplay", step3) ; 36 InspectorTest.invokeAsyncWithTimeline("updateSubframeAndDisplay", step3) ;
37 } 37 }
38 38
39 function step3(records) 39 function step3(records)
40 { 40 {
41 var paintRecord = InspectorTest.findFirstTimelineRecord(WebInspector.Tim elineModel.RecordType.Paint); 41 var paintRecord = InspectorTest.findFirstTimelineRecord(WebInspector.Tim elineModel.RecordType.Paint);
42 InspectorTest.assertTrue(paintRecord, "Paint record with subframe paint not found"); 42 InspectorTest.assertTrue(paintRecord, "Paint record with subframe paint not found");
43 var topQuad = paintRecord.data().clip; 43 var topQuad = paintRecord.traceEvent().args["data"].clip;
44 var subframePaint = paintRecord.children()[0]; 44 var subframePaint = paintRecord.children()[0];
45 var subframeQuad = subframePaint.data().clip; 45 var subframeQuad = subframePaint.traceEvent().args["data"].clip;
46 InspectorTest.assertEquals(8, topQuad.length); 46 InspectorTest.assertEquals(8, topQuad.length);
47 InspectorTest.assertEquals(8, subframeQuad.length); 47 InspectorTest.assertEquals(8, subframeQuad.length);
48 InspectorTest.assertGreaterOrEqual(subframeQuad[0], topQuad[0]); 48 InspectorTest.assertGreaterOrEqual(subframeQuad[0], topQuad[0]);
49 InspectorTest.assertGreaterOrEqual(subframeQuad[1], topQuad[1]); 49 InspectorTest.assertGreaterOrEqual(subframeQuad[1], topQuad[1]);
50 InspectorTest.assertGreaterOrEqual(topQuad[2], subframeQuad[2]); 50 InspectorTest.assertGreaterOrEqual(topQuad[2], subframeQuad[2]);
51 InspectorTest.assertGreaterOrEqual(subframeQuad[3], topQuad[3]); 51 InspectorTest.assertGreaterOrEqual(subframeQuad[3], topQuad[3]);
52 InspectorTest.assertGreaterOrEqual(topQuad[4], subframeQuad[4]); 52 InspectorTest.assertGreaterOrEqual(topQuad[4], subframeQuad[4]);
53 InspectorTest.assertGreaterOrEqual(topQuad[5], subframeQuad[5]); 53 InspectorTest.assertGreaterOrEqual(topQuad[5], subframeQuad[5]);
54 InspectorTest.assertGreaterOrEqual(subframeQuad[6], topQuad[6]); 54 InspectorTest.assertGreaterOrEqual(subframeQuad[6], topQuad[6]);
55 InspectorTest.assertGreaterOrEqual(topQuad[7], subframeQuad[7]); 55 InspectorTest.assertGreaterOrEqual(topQuad[7], subframeQuad[7]);
56 56
57 InspectorTest.completeTest(); 57 InspectorTest.completeTest();
58 } 58 }
59 } 59 }
60 60
61 </script> 61 </script>
62 </head> 62 </head>
63 63
64 <body onload="runTest()"> 64 <body onload="runTest()">
65 <p> 65 <p>
66 Tests the Timeline API instrumentation of a paint event 66 Tests the Timeline API instrumentation of a paint event
67 </p> 67 </p>
68 <iframe src="resources/timeline-iframe-paint.html" style="position: absolute; le ft: 40px; top: 40px; width: 100px; height: 100px; border: none"></iframe> 68 <iframe src="resources/timeline-iframe-paint.html" style="position: absolute; le ft: 40px; top: 40px; width: 100px; height: 100px; border: none"></iframe>
69 </body> 69 </body>
70 </html> 70 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698