We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
getByText
screen
1 parent ebb4a6b commit be54187Copy full SHA for be54187
docs/react-testing-library/cheatsheet.mdx
@@ -21,7 +21,7 @@ test('loads items eventually', async () => {
21
render(<Page />)
22
23
// Click button
24
- fireEvent.click(getByText('Load'))
+ fireEvent.click(screen.getByText('Load'))
25
26
// Wait for page to update with query text
27
const items = await screen.findAllByText(/Item #[0-9]: /)
0 commit comments