react-testing-library version: 1.0.1
node version: n/a
npm (or yarn) version: n/a
Relevant code or config
expect(queryByTestId('greeting-text').textContent).toBe('hello there')
What you did:
Did not render the element with 'greeting-text' identifier.
What happened:
TypeError: Cannot read property textContent of null
Reproduction repository:
https://codesandbox.io/s/4q3zol71y9
Problem description:
The error does not describe what has gone wrong.
Suggested solution:
Throw a user-friendly error.
react-testing-libraryversion: 1.0.1nodeversion: n/anpm(oryarn) version: n/aRelevant code or config
What you did:
Did not render the element with
'greeting-text'identifier.What happened:
TypeError: Cannot read property textContent of null
Reproduction repository:
https://codesandbox.io/s/4q3zol71y9
Problem description:
The error does not describe what has gone wrong.
Suggested solution:
Throw a user-friendly error.