You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
🚨 If you find yourself using container to query for rendered elements then you should reconsider! The other queries are designed to be more resilient to changes that will be made to the component you're testing. Avoid using container to query for elements!
Should the material not push this behaviour? Parts of the material use this quite actively, like this:
let container = render(
<Togglable buttonLabel="show...">
...
</Togglable>
).container
const div = container.querySelector('.togglableContent')
I found this in the documentation:
🚨 If you find yourself using container to query for rendered elements then you should reconsider! The other queries are designed to be more resilient to changes that will be made to the component you're testing. Avoid using container to query for elements!
Should the material not push this behaviour? Parts of the material use this quite actively, like this:
Should we use the library specific queries overviewed in https://testing-library.com/docs/queries/about#types-of-queries
The text was updated successfully, but these errors were encountered: