-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Update testing section #1404
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
Update testing section #1404
Conversation
✅ Deploy Preview for react-navigation-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
In the Example 4, adding |
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.
Looks good to me! I've added few suggestions & changes requests.
IMO this is is.
I'll want to get input from @satya164 before merging though.
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.
We need to improve the PR description slightly before we land it.
Other than that - great job. Also shoutout to @AnCichocka for the bulk of the work.
PR description updated. |
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.
Thanks for the PR!
I left some comments to align the examples with current best practices. I only commented on a few of the usage sites, but they apply to all other places using similar code.
@satya164 I have a little problem with documenting the usage of fake timers. After changing tests to async (to use User Event API instead of Fire Event API), they work (without warnings) only if I setup the fake timers (even when I don't need to use The warning I get is |
hey @kligarski would it be possible to create a test repo that i can check? you can share with me on discord and i'll check it as soon as i can. |
This PR is a continuation of (#1374).
Description
Adding examples to the testing section of the documentation ("Testing with Jest").
Changes
react-native-reanimated
and added a link to the docs of Reanimated,react-native-screens
(from previous PR),tabPress
,useFocusEffect
and data fetchinggetBy
vsqueryBy
according to the suggestion from the previous PR (Update testing section #1374 (comment))