OLD | NEW |
1 // This script is supposed to be evaluated in dummy inspector front-end which is
loaded from | 1 // This script is supposed to be evaluated in dummy inspector front-end which is
loaded from |
2 // ../../../http/tests/inspector-protocol/resources/protocol-test.html and the r
elative paths | 2 // ../../../http/tests/inspector-protocol/resources/protocol-test.html and the r
elative paths |
3 // below are relative to that location. | 3 // below are relative to that location. |
4 | 4 |
5 if (!window.WebInspector) | 5 if (!window.WebInspector) |
6 window.WebInspector = {}; | 6 window.WebInspector = {}; |
7 InspectorTest.importScript("../../../../../Source/devtools/front_end/platform/Pr
omise.js"); | |
8 InspectorTest.importScript("../../../../../Source/devtools/front_end/platform/ut
ilities.js"); | |
9 InspectorTest.importScript("../../../../../Source/devtools/front_end/common/UISt
ring.js"); | 7 InspectorTest.importScript("../../../../../Source/devtools/front_end/common/UISt
ring.js"); |
| 8 InspectorTest.importScript("../../../../../Source/devtools/front_end/common/util
ities.js"); |
10 InspectorTest.importScript("../../../../../Source/devtools/front_end/profiler/He
apSnapshotCommon.js"); | 9 InspectorTest.importScript("../../../../../Source/devtools/front_end/profiler/He
apSnapshotCommon.js"); |
11 InspectorTest.importScript("../../../../../Source/devtools/front_end/heap_snapsh
ot_worker/HeapSnapshot.js"); | 10 InspectorTest.importScript("../../../../../Source/devtools/front_end/heap_snapsh
ot_worker/HeapSnapshot.js"); |
12 InspectorTest.importScript("../../../../../Source/devtools/front_end/heap_snapsh
ot_worker/JSHeapSnapshot.js"); | 11 InspectorTest.importScript("../../../../../Source/devtools/front_end/heap_snapsh
ot_worker/JSHeapSnapshot.js"); |
13 | 12 |
14 InspectorTest.fail = function(message) | 13 InspectorTest.fail = function(message) |
15 { | 14 { |
16 InspectorTest.log("FAIL: " + message); | 15 InspectorTest.log("FAIL: " + message); |
17 InspectorTest.completeTest(); | 16 InspectorTest.completeTest(); |
18 } | 17 } |
19 | 18 |
(...skipping 17 matching lines...) Expand all Loading... |
37 var parsed = JSON.parse(serializedSnapshot); | 36 var parsed = JSON.parse(serializedSnapshot); |
38 parsed.nodes = new Uint32Array(parsed.nodes); | 37 parsed.nodes = new Uint32Array(parsed.nodes); |
39 parsed.edges = new Uint32Array(parsed.edges); | 38 parsed.edges = new Uint32Array(parsed.edges); |
40 var snapshot = new WebInspector.JSHeapSnapshot(parsed, new WebInspector.
HeapSnapshotProgress()); | 39 var snapshot = new WebInspector.JSHeapSnapshot(parsed, new WebInspector.
HeapSnapshotProgress()); |
41 callback(snapshot); | 40 callback(snapshot); |
42 InspectorTest.log("SUCCESS: didGetHeapSnapshot"); | 41 InspectorTest.log("SUCCESS: didGetHeapSnapshot"); |
43 InspectorTest.completeTest(); | 42 InspectorTest.completeTest(); |
44 } | 43 } |
45 InspectorTest.sendCommand("HeapProfiler.takeHeapSnapshot", {}, didTakeHeapSn
apshot); | 44 InspectorTest.sendCommand("HeapProfiler.takeHeapSnapshot", {}, didTakeHeapSn
apshot); |
46 } | 45 } |
OLD | NEW |