1. 13
    Get Elements With an Associated Test id Attribute Using the byTestId Query
    50s

Get Elements With an Associated Test id Attribute Using the byTestId Query

Daniel Afonso
InstructorDaniel Afonso
Share this video with your friends

Social Share Links

Send Tweet
Published a year ago
Updated a year ago

Sometimes, none of the queries above will work for you. Instead of focusing on implementation details, the React Testing Library gives you a controlled way of doing so: using data-testid!

In this lesson, we are going to look at the one query that belongs to the TestId family and should be used as a last resort only: the byTestId query.