blob: 112bd621ff2251ef187bda739789a7d10ecbae09 [file] [log] [blame]
This tests that titleUIElement works correctly even when things change dynamically.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS axElement('control1').nameElementAtIndex(0).isEqual(axElement('label1')) is true
PASS axElement('control2').nameElementAtIndex(0).isEqual(axElement('label2')) is true
PASS hasTitleUIElement(axElement('control3')) is false
PASS document.getElementById('label3').setAttribute('for', 'control3'); axElement('control3').nameElementAtIndex(0).isEqual(axElement('label3')) is true
PASS var label4Element = createLabelWithIdAndForAttribute('label4', 'control4'); hasTitleUIElement(axElement('control4')) is false
PASS document.getElementById('container').appendChild(label4Element); hasTitleUIElement(axElement('control4')) is true
PASS axElement('control4').nameElementAtIndex(0).isEqual(axElement('label4')) is true
PASS label4Element.parentElement.removeChild(label4Element); hasTitleUIElement(axElement('control4')) is false
PASS hasTitleUIElement(axElement('control5')) is false
PASS reparentNodeIntoContainer(document.getElementById('control5'), document.getElementById('label5')); document.body.offsetTop; axElement('control5').nameElementAtIndex(0) != null is true
PASS axElement('control5').nameElementAtIndex(0).isEqual(axElement('label5')) is true
PASS axElement('control6').nameElementAtIndex(0).isEqual(axElement('label6b')) is true
PASS newLabel6Element = createLabelWithIdAndForAttribute('label6a', 'control6'); document.body.insertBefore(newLabel6Element, document.body.firstChild); axElement('control6').nameElementAtIndex(0).isEqual(axElement('label6a')) is true
PASS document.body.removeChild(newLabel6Element); axElement('control6').nameElementAtIndex(0).isEqual(axElement('label6b')) is true
PASS successfullyParsed is true
TEST COMPLETE