Index: third_party/WebKit/LayoutTests/inspector-protocol/dom/dom-request-child-nodes-traverse-frames.html |
diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/dom/dom-request-child-nodes-traverse-frames.html b/third_party/WebKit/LayoutTests/inspector-protocol/dom/dom-request-child-nodes-traverse-frames.html |
deleted file mode 100644 |
index 60dd438e8aed8696bf1d2740cc37f9d8c96fbaff..0000000000000000000000000000000000000000 |
--- a/third_party/WebKit/LayoutTests/inspector-protocol/dom/dom-request-child-nodes-traverse-frames.html |
+++ /dev/null |
@@ -1,106 +0,0 @@ |
-<html> |
-<head> |
-<script type="text/javascript" src="../../http/tests/inspector-protocol/resources/inspector-protocol-test.js"></script> |
-<script type="text/javascript"> |
- |
-function test() |
-{ |
- getDocument(); |
- |
- function getDocument() |
- { |
- InspectorTest.sendCommand("DOM.getDocument", {}, function(messageObject) { |
- if (messageObject.hasOwnProperty("error")) |
- InspectorTest.log("Backend error: " + messageObject.error.message + " (" + messageObject.error.code + ")\n"); |
- |
- var bodyId = messageObject.result.root.children[0].children[1].nodeId; |
- requestChildNodes(bodyId); |
- }); |
- }; |
- |
- function requestChildNodes(bodyId) |
- { |
- InspectorTest.sendCommand("DOM.requestChildNodes", {"nodeId": bodyId, "depth": -1}, function(messageObject) { |
- if (messageObject.hasOwnProperty("error")) |
- InspectorTest.log("Backend error: " + messageObject.error.message + " (" + messageObject.error.code + ")\n"); |
- }); |
- |
- InspectorTest.eventHandler["DOM.setChildNodes"] = function(messageObject) |
- { |
- var iframeContentDocument = messageObject.params.nodes[0].children[0].children[0].children[0].contentDocument; |
- if (iframeContentDocument.children) { |
- InspectorTest.log("Error IFrame node should not include children: " + JSON.stringify(iframeContentDocument, null, " ")); |
- InspectorTest.completeTest(); |
- } else { |
- getDocumentIncludingIframe(); |
- } |
- }; |
- }; |
- |
- function getDocumentIncludingIframe() |
- { |
- InspectorTest.sendCommand("DOM.getDocument", {"pierce": true}, function(messageObject) { |
- if (messageObject.hasOwnProperty("error")) |
- InspectorTest.log("Backend error: " + messageObject.error.message + " (" + messageObject.error.code + ")\n"); |
- |
- var bodyId = messageObject.result.root.children[0].children[1].nodeId; |
- requestAllChildNodesIncludingIframe(bodyId); |
- }); |
- }; |
- |
- function replacePropertyRecursive(object, propertyNameToReplace) |
- { |
- for (var propertyName in object) { |
- if (!object.hasOwnProperty(propertyName)) |
- continue; |
- if (propertyName === propertyNameToReplace) { |
- object[propertyName] = "???"; |
- } else if (typeof object[propertyName] === "object") { |
- replacePropertyRecursive(object[propertyName], propertyNameToReplace); |
- } |
- } |
- } |
- |
- function requestAllChildNodesIncludingIframe(bodyId) |
- { |
- InspectorTest.sendCommand("DOM.requestChildNodes", {"nodeId": bodyId, "depth": -1, "pierce": true}, function(messageObject) { |
- if (messageObject.hasOwnProperty("error")) |
- InspectorTest.log("Backend error: " + messageObject.error.message + " (" + messageObject.error.code + ")\n"); |
- }); |
- |
- InspectorTest.eventHandler["DOM.setChildNodes"] = function(messageObject) |
- { |
- // Replace properties that tend to change every run. |
- replacePropertyRecursive(messageObject, "frameId"); |
- replacePropertyRecursive(messageObject, "documentURL"); |
- replacePropertyRecursive(messageObject, "baseURL"); |
- function stabilize(key, value) { |
- var unstableKeys = ["backendNodeId"]; |
- if (unstableKeys.indexOf(key) !== -1) |
- return "<" + typeof(value) + ">"; |
- return value; |
- } |
- InspectorTest.log(JSON.stringify(messageObject, stabilize, " ")); |
- InspectorTest.completeTest(); |
- }; |
- }; |
-}; |
- |
-window.addEventListener("DOMContentLoaded", function () { |
- runTest(); |
-}, false); |
- |
-</script> |
-</head> |
-<body> |
- |
-<div id="depth-1"> |
- <div id="depth-2"> |
- <div id="depth-3"> |
- <iframe src="resources/iframe.html"></iframe> |
- </div> |
- </div> |
-</div> |
- |
-</body> |
-</html> |