<html>
<script>
if (window.testRunner)
    testRunner.dumpAsText();

window.onload = function() {
    var selection = window.getSelection();
    selection.selectAllChildren(document);
    selection.collapseToEnd();
    var element = document.activeElement;
    var parent = element.parentNode;
    document.open();
    if (selection.containsNode(element, true))
        document.write("FAIL: selection.containsNode should return false");
    else
        document.write("PASS");
    document.close();
}
</script>
</html>
