Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove orphaned children accessible tests, or clarify ARIA spec #109

Closed
nmlapre opened this issue Feb 22, 2024 · 5 comments · Fixed by web-platform-tests/wpt#45032
Closed
Labels
Agenda+ bug Something isn't working

Comments

@nmlapre
Copy link

nmlapre commented Feb 22, 2024

The web platform tests have a number of cases verifying the roles of "orphaned" accessible nodes with expected parent/child role relationships. For instance, one test expects this markup:

<button role="gridcell">x</button>

to have role "button," rather than role "gridcell," since the supposed gridcell exists outside of the context of a row.

After reviewing the ARIA spec, it seems to me that this isn't the responsibility of the user agent. In the case of gridcell, for instance, the spec puts the onus on authors:

Authors MUST ensure elements with role gridcell are accessibility children of an element with the role row.

This language appears in all of the parent/child role relationship cases I reviewed. Namely: listbox/option, menu/menuitem (and variants), table/row, table/rowgroup, row/gridcell, row/rowheader, row/columnheader, list/listitem, tablist/tab, and tree/treeitem.

Similarly, section 9.2 mentions:

User agents are not responsible for logical validation, such as the following:
[...]
4. Elements that do not correctly observe required child / parent role relationships or that appear elsewhere than in their required parent.

It seems to me that the tests are verifying a remediation not required by the ARIA spec. After discussing with @jcsteh, we're not sure whether we should implement this behavior in Firefox. Should we strike the tests from the WPT repo, or are the tests valid? Do we need a clarification of the ARIA spec?


Referenced tests:

@cookiecrook
Copy link
Collaborator

cookiecrook commented Mar 6, 2024

Thanks for filing @nmlapre! I think we could move these specific tests into a .tentative. file or series of files. In the meantime, I'll also file a new ARIA issue.

@cookiecrook
Copy link
Collaborator

cookiecrook commented Mar 6, 2024

Unassigning myself in case someone can get to this WPT PR before I do. Please assign yourself if/when you intend to work on this imminently.

Note: this will change the 2024 Accessibility Focus Area results by removing quite a few subtests, so there will be some scrutiny on the related PR.

@nmlapre
Copy link
Author

nmlapre commented Mar 11, 2024

I'm not able to assign myself to this issue (permissions with the repo, I think) but I just posted a PR with the changes: web-platform-tests/wpt#45032. I decided to lump all the tests in a single, segmented .tentative file.

@cookiecrook
Copy link
Collaborator

Seems like the relevant reqs may be covered sufficiently in the Core-AAM spec. web-platform-tests/wpt#45032 (review)

@cookiecrook
Copy link
Collaborator

FYI, we've received some additional implementation concerns about the "orphaned roles" prose. Seems like one or more implementations may be working around this in the test context primarily, which defeats the purpose of testing… I'll be opening an ARIA spec issue and possibly moving some of these tests to .tentative files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Agenda+ bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants