blob: 0d5244dba5dbf85a643a65a5945ded09b9fd1b9d [file] [log] [blame]
<html>
<head>
<script>
function runTests() {
if (window.layoutTestController) {
layoutTestController.dumpAsText();
layoutTestController.dumpTitleChanges();
}
document.title = '1. setting document.title';
title = document.getElementsByTagName('title').item(0);
title.text = '2. setting title.text';
newTitle = document.createElement('title');
newTitle.appendChild(document.createTextNode('3. appending a new title node (should not trigger a title change)'));
document.getElementsByTagName('head').item(0).appendChild(newTitle);
// Remove both title elements
titleElements = document.getElementsByTagName('title');
while (titleElements.length) {
titleElement = titleElements[titleElements.length - 1];
titleElement.parentNode.removeChild(titleElement);
}
}
</script>
<title>Initial title</title>
</head>
<body onload="runTests();" >
</body>
</html>