Skip to content

Commit

Permalink
chore(readme): mocking with Jest example (#610)
Browse files Browse the repository at this point in the history
  • Loading branch information
rizwankce authored and jgcmarins committed Oct 21, 2019
1 parent 736a8ac commit 796ac3a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -396,3 +396,13 @@ static sharePDFWithAndroid(fileUrl, type) {
}
```
#### Mocking with Jest
- To mock when using Jest. Add the below line on your `__mock__` directory.
```js
jest.mock('react-native-share', () => ({
default: jest.fn(),
}));
```

0 comments on commit 796ac3a

Please sign in to comment.