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 17 matching lines...) Expand all Loading... |
28 InspectorTest.invokeAsyncWithTimeline("performActions", finish); | 28 InspectorTest.invokeAsyncWithTimeline("performActions", finish); |
29 | 29 |
30 var linkifier = new WebInspector.Linkifier(); | 30 var linkifier = new WebInspector.Linkifier(); |
31 | 31 |
32 var recordTypes = ["TimerInstall", "TimerRemove", "FunctionCall"]; | 32 var recordTypes = ["TimerInstall", "TimerRemove", "FunctionCall"]; |
33 function formatter(record) | 33 function formatter(record) |
34 { | 34 { |
35 if (recordTypes.indexOf(record.type()) === -1) | 35 if (recordTypes.indexOf(record.type()) === -1) |
36 return; | 36 return; |
37 | 37 |
38 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceEvent
(record.traceEvent(), linkifier); | 38 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceEvent
(record.traceEvent(), InspectorTest.timelineModel().target(), linkifier); |
39 if (details) | 39 if (details) |
40 InspectorTest.addResult("details.textContent for " + record.type() +
" event: '" + details.textContent + "'"); | 40 InspectorTest.addResult("details.textContent for " + record.type() +
" event: '" + details.textContent + "'"); |
41 } | 41 } |
42 | 42 |
43 function finish() | 43 function finish() |
44 { | 44 { |
45 InspectorTest.printTimelinePresentationRecords(null, formatter); | 45 InspectorTest.printTimelinePresentationRecords(null, formatter); |
46 InspectorTest.completeTest(); | 46 InspectorTest.completeTest(); |
47 } | 47 } |
48 } | 48 } |
49 | 49 |
50 if (!window.testRunner) | 50 if (!window.testRunner) |
51 setTimeout(performActions, 2000); | 51 setTimeout(performActions, 2000); |
52 | 52 |
53 </script> | 53 </script> |
54 </head> | 54 </head> |
55 | 55 |
56 <body onload="runTest()"> | 56 <body onload="runTest()"> |
57 <p> | 57 <p> |
58 Test that checks location resolving mechanics for TimerInstall TimerRemove and F
unctionCall events with scriptId. | 58 Test that checks location resolving mechanics for TimerInstall TimerRemove and F
unctionCall events with scriptId. |
59 </p><p> | 59 </p><p> |
60 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. | 60 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. |
61 </p> | 61 </p> |
62 </body> | 62 </body> |
63 </html> | 63 </html> |
OLD | NEW |