| 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="heap-snapshot-test.js"></script> | 4 <script src="heap-snapshot-test.js"></script> |
| 5 <script> | 5 <script> |
| 6 | 6 |
| 7 function test() | 7 function test() |
| 8 { | 8 { |
| 9 var instanceCount = 25; | 9 var instanceCount = 25; |
| 10 function createHeapSnapshot() | 10 function createHeapSnapshot() |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 } | 99 } |
| 100 | 100 |
| 101 function step2() | 101 function step2() |
| 102 { | 102 { |
| 103 InspectorTest.findAndExpandGCRoots(step3); | 103 InspectorTest.findAndExpandGCRoots(step3); |
| 104 } | 104 } |
| 105 | 105 |
| 106 function step3(row) | 106 function step3(row) |
| 107 { | 107 { |
| 108 InspectorTest.assertEquals("(GC roots)", row._name, "(GC roots)
object"); | 108 InspectorTest.assertEquals("(GC roots)", row._name, "(GC roots)
object"); |
| 109 InspectorTest.assertEquals(0, row._distance, "(GC roots) distanc
e should be zero"); | 109 InspectorTest.assertEquals("\u2212", row.data.distance, "(GC roo
ts) distance should be zero"); |
| 110 InspectorTest.findAndExpandWindow(step4); | 110 InspectorTest.findAndExpandWindow(step4); |
| 111 } | 111 } |
| 112 | 112 |
| 113 function step4(row) | 113 function step4(row) |
| 114 { | 114 { |
| 115 InspectorTest.assertEquals("Window", row._name, "Window object")
; | 115 InspectorTest.assertEquals("Window", row._name, "Window object")
; |
| 116 InspectorTest.assertEquals(distance, row._distance, "Window dist
ance should be 1"); | 116 InspectorTest.assertEquals(distance, row._distance, "Window dist
ance should be 1"); |
| 117 var child = InspectorTest.findMatchingRow(function (obj) { retur
n obj._referenceName === "next"; }, row); | 117 var child = InspectorTest.findMatchingRow(function (obj) { retur
n obj._referenceName === "next"; }, row); |
| 118 InspectorTest.assertEquals(true, !!child, "next found"); | 118 InspectorTest.assertEquals(true, !!child, "next found"); |
| 119 InspectorTest.expandRow(child, step5); | 119 InspectorTest.expandRow(child, step5); |
| (...skipping 23 matching lines...) Expand all Loading... |
| 143 </script> | 143 </script> |
| 144 </head> | 144 </head> |
| 145 <body onload="runTest()"> | 145 <body onload="runTest()"> |
| 146 <p> | 146 <p> |
| 147 Tests Containment view of detailed heap snapshots. | 147 Tests Containment view of detailed heap snapshots. |
| 148 The "Show All" button must show all nodes. | 148 The "Show All" button must show all nodes. |
| 149 Test object distances calculation. | 149 Test object distances calculation. |
| 150 </p> | 150 </p> |
| 151 </body> | 151 </body> |
| 152 </html> | 152 </html> |
| OLD | NEW |