| OLD | NEW |
| 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 test() | 7 function test() |
| 8 { | 8 { |
| 9 function performActions(callback) | 9 function performActions(callback) |
| 10 { | 10 { |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 | 32 |
| 33 var linkifier = new WebInspector.Linkifier(); | 33 var linkifier = new WebInspector.Linkifier(); |
| 34 | 34 |
| 35 var recordTypes = ["TimerInstall", "TimerRemove", "FunctionCall"]; | 35 var recordTypes = ["TimerInstall", "TimerRemove", "FunctionCall"]; |
| 36 function formatter(record) | 36 function formatter(record) |
| 37 { | 37 { |
| 38 if (recordTypes.indexOf(record.type()) === -1) | 38 if (recordTypes.indexOf(record.type()) === -1) |
| 39 return; | 39 return; |
| 40 | 40 |
| 41 var detailsText = WebInspector.TimelineUIUtils.buildDetailsTextForTraceE
vent(record.traceEvent(), InspectorTest.timelineModel().target()); | 41 var detailsText = WebInspector.TimelineUIUtils.buildDetailsTextForTraceE
vent(record.traceEvent(), InspectorTest.timelineModel().target()); |
| 42 InspectorTest.addResult("detailsTextContent for " + record.type() + " ev
ent: '" + detailsText.replace(/VM[\d]+/, "VM") + "'"); | 42 InspectorTest.addResult("detailsTextContent for " + record.type() + " ev
ent: '" + detailsText + "'"); |
| 43 | 43 |
| 44 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceEvent
(record.traceEvent(), InspectorTest.timelineModel().target(), linkifier); | 44 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceEvent
(record.traceEvent(), InspectorTest.timelineModel().target(), linkifier); |
| 45 if (!details) | 45 if (!details) |
| 46 return; | 46 return; |
| 47 InspectorTest.addResult("details.textContent for " + record.type() + " e
vent: '" + details.textContent.replace(/VM[\d]+/, "VM") + "'"); | 47 InspectorTest.addResult("details.textContent for " + record.type() + " e
vent: '" + details.textContent.replace(/VM[\d]+/, "VM") + "'"); |
| 48 } | 48 } |
| 49 | 49 |
| 50 function finish() | 50 function finish() |
| 51 { | 51 { |
| 52 InspectorTest.printTimelinePresentationRecords(null, formatter); | 52 InspectorTest.printTimelinePresentationRecords(null, formatter); |
| 53 InspectorTest.completeTest(); | 53 InspectorTest.completeTest(); |
| 54 } | 54 } |
| 55 } | 55 } |
| 56 | 56 |
| 57 if (!window.testRunner) | 57 if (!window.testRunner) |
| 58 setTimeout(performActions, 2000); | 58 setTimeout(performActions, 2000); |
| 59 | 59 |
| 60 </script> | 60 </script> |
| 61 </head> | 61 </head> |
| 62 | 62 |
| 63 <body onload="runTest()"> | 63 <body onload="runTest()"> |
| 64 <p> | 64 <p> |
| 65 Test that checks location resolving mechanics for TimerInstall TimerRemove and F
unctionCall events with scriptId. | 65 Test that checks location resolving mechanics for TimerInstall TimerRemove and F
unctionCall events with scriptId. |
| 66 </p><p> | 66 </p><p> |
| 67 It expects two FunctionCall for InjectedScript, two TimerInstall events, two Fun
ctionCall events and one TimerRemove event to be logged with performActions.js s
cript name and some line number. | 67 It expects two FunctionCall for InjectedScript, two TimerInstall events, two Fun
ctionCall events and one TimerRemove event to be logged with performActions.js s
cript name and some line number. |
| 68 </p> | 68 </p> |
| 69 </body> | 69 </body> |
| 70 </html> | 70 </html> |
| OLD | NEW |