Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/oieduardorabelo/jest-complex-mocks-examples
Using Jest mock's in complex HOC's like react-redux/connect() and react-intl
https://github.com/oieduardorabelo/jest-complex-mocks-examples
Last synced: 13 days ago
JSON representation
Using Jest mock's in complex HOC's like react-redux/connect() and react-intl
- Host: GitHub
- URL: https://github.com/oieduardorabelo/jest-complex-mocks-examples
- Owner: oieduardorabelo
- Created: 2017-06-23T12:34:32.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-07-01T08:02:17.000Z (over 7 years ago)
- Last Synced: 2025-01-13T14:50:15.814Z (about 1 month ago)
- Language: JavaScript
- Size: 251 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Jest complex mocks
This repository have basic examples of using Jest mock's functions in complex HOC.
Here, we're mocking:
- `react-redux` - Component using `connect()`
- `react-intl` - Components using `` HOC and `injectIntl`
- `react-router-dom` - Example of testing components with `withRouter`Making component test simple and easy again!
Example of: https://medium.com/@oieduardorabelo/testando-com-jest-15-dicas-para-mudar-seu-dia-17935520511e