-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[Bug]: getByRole() doesn't find <section> elements with title attribute #31428
Comments
You need to set an explicit aria label as per |
(It might be easier to use |
Chrome will sometimes step away from the spec and use accessible name heuristics. We'll check why they did it, but we seem to be correct as per the spec on this one. |
Closing as per above, please feel free to open a new issue if this does not cover your use case. |
Version
1.44.1
Steps to reproduce
npm install
npx playwright test
Expected behavior
I expect
page.getByRole('region', { name: 'WWF History' })
to find the<section title="WWF History">
element.Actual behavior
The element is not found.
Additional context
Screenshot of the DOM
Environment
The text was updated successfully, but these errors were encountered: