-
Notifications
You must be signed in to change notification settings - Fork 21
Labels
Milestone
Description
Describe the bug
When recording a page that has multiple elements with the same data-testid, interacting with one of them will generate a script that causes the following error:
ERRO[0009] Uncaught (in promise) clicking on "internal:attr=[data-testid='data-testid Nav menu item']": strict mode violation, multiple elements returned for selector query executor=shared-iterations scenario=default
The reason is that we're not checking whether the test id is unique while recording.
Steps to reproduce the problem
- Sign in to a Grafana stack
- Expand an item in the sidebar menu
- Export and run the script
Expected behavior
The script should pass
Actual behavior
Script fails with a strict mode violation:
ERRO[0009] Uncaught (in promise) clicking on "internal:attr=[data-testid='data-testid Nav menu item']": strict mode violation, multiple elements returned for selector query executor=shared-iterations scenario=default
Grafana k6 Studio version
v1.8.0
OS
Any
Reactions are currently unavailable