Files
tubestation/testing
Edgar Chen 3d0d8aa9c3 Bug 834208 - Align the document name getter with the spec and other browsers; r=smaug,devtools-reviewers,ochameau
Original patch: 7d93b7e3c1
Original author: Aryeh Gregor <ayg@aryeh.name>

According to the spec,
 - https://html.spec.whatwg.org/#dom-document-nameditem
 - https://html.spec.whatwg.org/#named-access-on-the-window-object

the document and window named getters return different values. This patch creates
a separated content list for document named getter while keeping the original
content list for the window named getter. Additionally, the content list now
includes both names and ids, in addition to the id list (which is still used for
other things like getElementById()).

This means one element might be on up to multiple lists, but this implementation
is necessary. Specifically, we must return a consistent live list for document.foo
and for window.foo, so they need to be stored separately and cannot be generated
on the fly from a single shared list.

Differential Revision: https://phabricator.services.mozilla.com/D240951
2025-03-20 15:42:43 +00:00
..

Common testing tools for mozilla codebase projects, test suite definitions
for automated test runs, tests that don't fit anywhere else, and other fun
stuff