| OLD | NEW |
| (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 |
| 7 function performActions() |
| 8 { |
| 9 var div = document.getElementById("foo") |
| 10 div.style.width = "10px"; |
| 11 return div.offsetWidth; |
| 12 } |
| 13 |
| 14 function test() |
| 15 { |
| 16 Runtime.experiments.enableForTest("timelineV8RuntimeCallStats"); |
| 17 WebInspector.settingForTest("showNativeFunctionsInJSProfile").set(true); |
| 18 var model = WebInspector.panels.timeline._model; |
| 19 InspectorTest.evaluateWithTimeline("performActions()", finish); |
| 20 |
| 21 function finish() |
| 22 { |
| 23 var frame = model.mainThreadEvents() |
| 24 .filter(e => e.name === WebInspector.TimelineModel.RecordType.JSFram
e) |
| 25 .map(e => e.args["data"]["callFrame"]) |
| 26 .find(frame => frame.functionName === "FunctionCallback" && frame.ur
l === "native V8Runtime"); |
| 27 InspectorTest.assertTrue(!!frame, "FunctionCallback frame not found"); |
| 28 InspectorTest.completeTest(); |
| 29 } |
| 30 } |
| 31 |
| 32 </script> |
| 33 </head> |
| 34 |
| 35 <body onload="runTest()"> |
| 36 <div id="foo" /> |
| 37 <p> |
| 38 Check that RuntimeCallStats are present in profile. |
| 39 </p> |
| 40 </body> |
| 41 </html> |
| OLD | NEW |