Skip to content

Jest integration docs not fixing [@RNC/AsyncStorage]: NativeModule: AsyncStorage is null. #566

Answered by tido64
WarrenBuffering asked this question in Q&A
Discussion options

You must be logged in to vote

You should create a folder named @react-native-async-storage instead of @react-native-community. Mocking is not unique to AsyncStorage, it is a feature of Jest. You can read more about mocks here: https://jestjs.io/docs/manual-mocks.

Replies: 3 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@WarrenBuffering
Comment options

@tido64
Comment options

Answer selected by WarrenBuffering
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #565 on March 23, 2021 14:09.