-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ref(react-testing-library): Introduce user-event #29638
Conversation
.vscode/settings.json
Outdated
@@ -7,7 +7,7 @@ | |||
"**/*.pyc": true, | |||
"build": true, | |||
"htmlcov": true, | |||
"node_modules": true, | |||
"node_modules": false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why false?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still working on it and will update this file as soon as I am done 😉
|
||
expect(container).toSnapshot(); | ||
}); | ||
}); | ||
|
||
it('can toggle collapsed state', async function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for some reason, the order the test was running in was causing an error. I'm going to check this out and create a follow-up PR
0ee1738
to
61c3635
Compare
@testing-library/user-event
fireEvent.*
withuserEvent.*
as it is recommended by the library author.More details:
https://kentcdodds.com/blog/common-mistakes-with-react-testing-library#not-using-testing-libraryuser-event