| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <meta charset=utf-8> | 2 <meta charset=utf-8> |
| 3 <title>Node.cloneNode</title> | 3 <title>Node.cloneNode</title> |
| 4 <link rel=help href="https://dom.spec.whatwg.org/#dom-node-clonenode"> | 4 <link rel=help href="https://dom.spec.whatwg.org/#dom-node-clonenode"> |
| 5 <script src="../../../../resources/testharness.js"></script> | 5 <script src="../../../../resources/testharness.js"></script> |
| 6 <script src="../../../../resources/testharnessreport.js"></script> | 6 <script src="../../../../resources/testharnessreport.js"></script> |
| 7 <div id=log></div> | 7 <div id=log></div> |
| 8 <script> | 8 <script> |
| 9 function assert_equal_node(nodeA, nodeB) { | 9 function assert_equal_node(nodeA, nodeB) { |
| 10 assert_equals(nodeB.nodeType, nodeA.nodeType, "nodeType"); | 10 assert_equals(nodeB.nodeType, nodeA.nodeType, "nodeType"); |
| (...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 create_element_and_check("source", HTMLSourceElement); | 144 create_element_and_check("source", HTMLSourceElement); |
| 145 create_element_and_check("spacer", HTMLElement); | 145 create_element_and_check("spacer", HTMLElement); |
| 146 create_element_and_check("span", HTMLSpanElement); | 146 create_element_and_check("span", HTMLSpanElement); |
| 147 create_element_and_check("strike", HTMLElement); | 147 create_element_and_check("strike", HTMLElement); |
| 148 create_element_and_check("style", HTMLStyleElement); | 148 create_element_and_check("style", HTMLStyleElement); |
| 149 create_element_and_check("sub", HTMLElement); | 149 create_element_and_check("sub", HTMLElement); |
| 150 create_element_and_check("summary", HTMLElement); | 150 create_element_and_check("summary", HTMLElement); |
| 151 create_element_and_check("sup", HTMLElement); | 151 create_element_and_check("sup", HTMLElement); |
| 152 create_element_and_check("table", HTMLTableElement); | 152 create_element_and_check("table", HTMLTableElement); |
| 153 create_element_and_check("tbody", HTMLTableSectionElement); | 153 create_element_and_check("tbody", HTMLTableSectionElement); |
| 154 create_element_and_check("td", HTMLTableCellElement); | 154 create_element_and_check("td", HTMLTableDataCellElement); |
| 155 create_element_and_check("template", HTMLTemplateElement); | 155 create_element_and_check("template", HTMLTemplateElement); |
| 156 create_element_and_check("textarea", HTMLTextAreaElement); | 156 create_element_and_check("textarea", HTMLTextAreaElement); |
| 157 create_element_and_check("th", HTMLTableCellElement); | 157 create_element_and_check("th", HTMLTableHeaderCellElement); |
| 158 create_element_and_check("time", HTMLTimeElement); | 158 create_element_and_check("time", HTMLTimeElement); |
| 159 create_element_and_check("title", HTMLTitleElement); | 159 create_element_and_check("title", HTMLTitleElement); |
| 160 create_element_and_check("tr", HTMLTableRowElement); | 160 create_element_and_check("tr", HTMLTableRowElement); |
| 161 create_element_and_check("tt", HTMLElement); | 161 create_element_and_check("tt", HTMLElement); |
| 162 create_element_and_check("track", HTMLTrackElement); | 162 create_element_and_check("track", HTMLTrackElement); |
| 163 create_element_and_check("u", HTMLElement); | 163 create_element_and_check("u", HTMLElement); |
| 164 create_element_and_check("ul", HTMLUListElement); | 164 create_element_and_check("ul", HTMLUListElement); |
| 165 create_element_and_check("var", HTMLElement); | 165 create_element_and_check("var", HTMLElement); |
| 166 create_element_and_check("video", HTMLVideoElement); | 166 create_element_and_check("video", HTMLVideoElement); |
| 167 create_element_and_check("unknown", HTMLUnknownElement); | 167 create_element_and_check("unknown", HTMLUnknownElement); |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 263 assert_equals(copy.childNodes[1].childNodes.length, 1); | 263 assert_equals(copy.childNodes[1].childNodes.length, 1); |
| 264 check_copy(grandChild, copy.childNodes[1].childNodes[0], HTMLDivElement); | 264 check_copy(grandChild, copy.childNodes[1].childNodes[0], HTMLDivElement); |
| 265 | 265 |
| 266 deep = false; | 266 deep = false; |
| 267 copy = parent.cloneNode(deep); | 267 copy = parent.cloneNode(deep); |
| 268 | 268 |
| 269 check_copy(parent, copy, HTMLDivElement); | 269 check_copy(parent, copy, HTMLDivElement); |
| 270 assert_equals(copy.childNodes.length, 0); | 270 assert_equals(copy.childNodes.length, 0); |
| 271 }, "node with children"); | 271 }, "node with children"); |
| 272 </script> | 272 </script> |
| OLD | NEW |