Skip to content

Commit eba7e82

Browse files
committed
Adds matcher name to multiple elements error
1 parent 373dbc4 commit eba7e82

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/queries/role.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,8 @@ function queryAllByRole(
107107
})
108108
}
109109

110-
const getMultipleError = (c, role) =>
111-
`Found multiple elements with the role "${role}"`
110+
const getMultipleError = (c, role, {name} = {}) =>
111+
`Found multiple elements with the role "${role}" matching ${name}`
112112

113113
const getMissingError = (
114114
container,

0 commit comments

Comments
 (0)