Was wondering was there a change with GetByRole that the name given is not exact?
Error: locator.click: Error: strict mode violation: getByRole('button', { name: 'Save' }) resolved to 2 elements: 1) <button granitebutton="" _nghost-cso-c107="" aria-haspop…>…</button> aka getByRole('button', { name: 'Saved Searches' }) 2) <button title="Save" disabled="true" granitebutton="" _n…>…</button> aka getByRole('button', { name: 'Save', exact: true })
Previously it ran correctly but should I now add to each locater the exact:true option?
This thread is trying to answer question "Was there a change with GetByRole that the name given is not exact?"
Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email [email protected].