Skip to content
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

Code fix based on new jest changes #2

Merged
merged 2 commits into from
Jul 13, 2018

Conversation

vlad-bezden
Copy link
Contributor

based on FB GitHub trace jestjs/jest#2567 you can't reference external data inside of mock function. You will get following error

The module factory of jest.mock() is not allowed to reference any out-of-scope variables.

To fix this you need to declare local variable instead

based on FB GitHub trace  jestjs/jest#2567 you can't reference external data inside of mock function. You will get following error

The module factory of `jest.mock()` is not allowed to reference any out-of-scope variables. 

To fix this you need to declare local variable instead
@techsachinkumar techsachinkumar merged commit d585e35 into PacktPublishing:master Jul 13, 2018
@vlad-bezden vlad-bezden deleted the patch-1 branch July 14, 2018 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants