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

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

Issue 1048663002: [invalidations] Convert invalidations to use TreeOutline (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update per reviewer comments Created 5 years, 8 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 | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../../http/tests/inspector/inspector-test.js"></script> 4 <script src="../../http/tests/inspector/inspector-test.js"></script>
5 <script src="../../http/tests/inspector/timeline-test.js"></script> 5 <script src="../../http/tests/inspector/timeline-test.js"></script>
6 <script> 6 <script>
7 function display(callback) 7 function display(callback)
8 { 8 {
9 requestAnimationFrame(function() { 9 requestAnimationFrame(function() {
10 var testElements = document.body.getElementsByClassName("testElement"); 10 var testElements = document.body.getElementsByClassName("testElement");
(...skipping 13 matching lines...) Expand all
24 Runtime.experiments.enableForTest("timelineInvalidationTracking"); 24 Runtime.experiments.enableForTest("timelineInvalidationTracking");
25 25
26 InspectorTest.invokeAsyncWithTimeline("display", function() { 26 InspectorTest.invokeAsyncWithTimeline("display", function() {
27 var record = InspectorTest.findFirstTimelineRecord(WebInspector.Timeline Model.RecordType.Paint); 27 var record = InspectorTest.findFirstTimelineRecord(WebInspector.Timeline Model.RecordType.Paint);
28 InspectorTest.addArray(record._event.invalidationTrackingEvents, Inspect orTest.InvalidationFormatters, "", "paint invalidations"); 28 InspectorTest.addArray(record._event.invalidationTrackingEvents, Inspect orTest.InvalidationFormatters, "", "paint invalidations");
29 29
30 var linkifier = new WebInspector.Linkifier(); 30 var linkifier = new WebInspector.Linkifier();
31 var target = InspectorTest.timelineModel().target(); 31 var target = InspectorTest.timelineModel().target();
32 var contentHelper = new WebInspector.TimelineDetailsContentHelper(target , linkifier, null, true); 32 var contentHelper = new WebInspector.TimelineDetailsContentHelper(target , linkifier, null, true);
33 WebInspector.TimelineUIUtils._generateCauses(record.traceEvent(), target , contentHelper); 33 WebInspector.TimelineUIUtils._generateCauses(record.traceEvent(), target , contentHelper);
34 var invalidationGroups = contentHelper.element.getElementsByClassName("i nvalidations-group"); 34 var invalidationsTree = contentHelper.element.getElementsByClassName("in validations-tree")[0];
35 var invalidationGroups = invalidationsTree.shadowRoot.getElementsByClass Name("header");
35 36
36 InspectorTest.assertEquals(invalidationGroups.length, 2); 37 InspectorTest.assertEquals(invalidationGroups.length, 2);
37 InspectorTest.assertEquals(invalidationGroups[0].textContent, 38 InspectorTest.assertEquals(invalidationGroups[0].textContent,
38 "Inline CSS style declaration was mutated for [ DIV class='testEleme nt' ], [ DIV class='testElement' ], and 2 others. (anonymous function) @ timelin e-grouped-invalidations.html:12"); 39 "Inline CSS style declaration was mutated for [ DIV class='testEleme nt' ], [ DIV class='testElement' ], and 2 others. (anonymous function) @ timelin e-grouped-invalidations.html:12");
39 InspectorTest.assertEquals(invalidationGroups[1].textContent, 40 InspectorTest.assertEquals(invalidationGroups[1].textContent,
40 "Inline CSS style declaration was mutated for [ DIV class='testEleme nt' ], [ DIV class='testElement' ], and 2 others. (anonymous function) @ timelin e-grouped-invalidations.html:13"); 41 "Inline CSS style declaration was mutated for [ DIV class='testEleme nt' ], [ DIV class='testElement' ], and 2 others. (anonymous function) @ timelin e-grouped-invalidations.html:13");
41 InspectorTest.completeTest(); 42 InspectorTest.completeTest();
42 }); 43 });
43 } 44 }
44 </script> 45 </script>
45 </head> 46 </head>
46 <body onload="runTest()"> 47 <body onload="runTest()">
47 <p>Tests grouped invalidations on the timeline.</p> 48 <p>Tests grouped invalidations on the timeline.</p>
48 <div class="testElement">P</div><div class="testElement">A</div> 49 <div class="testElement">P</div><div class="testElement">A</div>
49 <div class="testElement">S</div><div class="testElement">S</div> 50 <div class="testElement">S</div><div class="testElement">S</div>
50 </body> 51 </body>
51 </html> 52 </html>
OLDNEW
« no previous file with comments | « no previous file | Source/devtools/devtools.gypi » ('j') | Source/devtools/front_end/timeline/TimelineUIUtils.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698