Created
November 12, 2018 08:46
-
-
Save Eightyplus/5a5d3d464fac74a9456613d31b66cb9d to your computer and use it in GitHub Desktop.
mock named exports, in this case `createFragmentContainer` and `withRouter`
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jest.mock('react-relay', () => ({ | |
createFragmentContainer: Component => props => <Component {...props} /> | |
})); | |
jest.mock('react-router', () => ({ | |
withRouter: Component => props => <Component {...props} /> | |
})); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment