Skip to content

Commit

Permalink
Documented another option to avoid warnings
Browse files Browse the repository at this point in the history
In React 16. This is actually the only feasible way when doing a full mount using https://github.com/Root-App/react-native-mock-render
refs jestjs#5258
  • Loading branch information
doronpr committed May 15, 2018
1 parent b7636e4 commit 6c81ff3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/TutorialReact.md
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,10 @@ mocked module fails these checks. Your options are:
types and will happily accept e.g. `SomeComponent`. You could check
snapshots using the test renderer, and check component behavior separately
using Enzyme.
4. Disable warnings all together (should be done in your jest setup file):
```js
jest.mock('fbjs/lib/warning', () => require('fbjs/lib/emptyFunction'));
```
### DOM Testing
Expand Down

0 comments on commit 6c81ff3

Please sign in to comment.