| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 | 3 |
| 4 <script src="../../http/tests/inspector/inspector-test.js"></script> | 4 <script src="../../http/tests/inspector/inspector-test.js"></script> |
| 5 <script src="../../http/tests/inspector/elements-test.js"></script> | 5 <script src="../../http/tests/inspector/elements-test.js"></script> |
| 6 <script> | 6 <script> |
| 7 | 7 |
| 8 function test() | 8 function test() |
| 9 { | 9 { |
| 10 InspectorTest.selectNodeWithId("container", step1); | 10 InspectorTest.selectNodeWithId("container", step1); |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 return; | 45 return; |
| 46 } | 46 } |
| 47 | 47 |
| 48 if (!(nodeIds && nodeIds.constructor && nodeIds.constructor.name === "Ar
ray")) | 48 if (!(nodeIds && nodeIds.constructor && nodeIds.constructor.name === "Ar
ray")) |
| 49 nodeIds = [nodeIds]; | 49 nodeIds = [nodeIds]; |
| 50 | 50 |
| 51 for (var i = 0; i < nodeIds.length; ++i) { | 51 for (var i = 0; i < nodeIds.length; ++i) { |
| 52 if (!nodeIds[i]) | 52 if (!nodeIds[i]) |
| 53 InspectorTest.addResult("no results"); | 53 InspectorTest.addResult("no results"); |
| 54 else { | 54 else { |
| 55 var node = WebInspector.domModel.nodeForId(nodeIds[i]); | 55 var node = InspectorTest.domModel.nodeForId(nodeIds[i]); |
| 56 InspectorTest.addResult("node id: " + node.getAttribute("id")); | 56 InspectorTest.addResult("node id: " + node.getAttribute("id")); |
| 57 } | 57 } |
| 58 } | 58 } |
| 59 next(); | 59 next(); |
| 60 } | 60 } |
| 61 } | 61 } |
| 62 </script> | 62 </script> |
| 63 </head> | 63 </head> |
| 64 | 64 |
| 65 <body onload="runTest()"> | 65 <body onload="runTest()"> |
| 66 <p> | 66 <p> |
| 67 Tests DOMAgent.querySelector and DOMAgent.querySelectorAll. | 67 Tests DOMAgent.querySelector and DOMAgent.querySelectorAll. |
| 68 </p> | 68 </p> |
| 69 | 69 |
| 70 <div id="id1" class="foo"></div> | 70 <div id="id1" class="foo"></div> |
| 71 <div id="id2" class="foo"></div> | 71 <div id="id2" class="foo"></div> |
| 72 | 72 |
| 73 <div id="container"> | 73 <div id="container"> |
| 74 <div id="id3" class="foo"></div> | 74 <div id="id3" class="foo"></div> |
| 75 <div id="id4" class="foo"></div> | 75 <div id="id4" class="foo"></div> |
| 76 <div id="id5" class="foo"></div> | 76 <div id="id5" class="foo"></div> |
| 77 <div id="id6" class="foo"></div> | 77 <div id="id6" class="foo"></div> |
| 78 </div> | 78 </div> |
| 79 | 79 |
| 80 </body> | 80 </body> |
| 81 </html> | 81 </html> |
| OLD | NEW |