2 <script src=
"../resources/js-test.js"></script>
4 <!-- Nodes inside a canvas get an AXNodeObject, not an AXLayoutObject. -->
10 description("Ensure that if we have an AXNodeObject with a raw pointer to a Node, the accessible object gets correctly detached if we adopt the node into a new document.");
12 // This triggers an asynchronous accessibility notification.
13 document
.getElementById("node2").setAttribute("aria-label", "Label");
15 // Adopt the node into a new document, then garbage-collect it.
16 // Make sure the notification doesn't try to access the invalid node.
17 document
.implementation
.createDocument("", null).adoptNode(node2
);