blob: 83a611e43090e80c1f8aa46094d3575b5eccbba6 [file] [log] [blame]
Test that the document's name getter returns an object element with id and name attributes set to the same value.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
objectElement = document.querySelector("object#someName");
PASS objectElement.getAttribute("name") is "someName"
PASS document.someName is objectElement
PASS objectElement.removeAttribute("id"); document.someName is objectElement
PASS objectElement.setAttribute("name", "otherName"); document.someName is undefined.
PASS document.otherName is objectElement
PASS objectElement.setAttribute("id", "otherName"); document.otherName is objectElement
PASS objectElement.parentNode.removeChild(objectElement); document.otherName is undefined.
PASS document.body.appendChild(objectElement); document.otherName is objectElement
PASS objectElement.setAttribute("id", "anotherName"); document.anotherName is objectElement
PASS document.otherName is objectElement
PASS objectElement.setAttribute("name", "anotherName"); document.otherName is undefined.
PASS document.anotherName is objectElement
imageElement = document.createElement("img"); document.body.appendChild(imageElement); imageElement.setAttribute("name", "anotherName");
PASS objectElement.parentNode.removeChild(objectElement); document.otherName is undefined.
PASS document.anotherName is imageElement