diff --git a/jest.config.js b/jest.config.js index 1f019f5e..e0b67339 100644 --- a/jest.config.js +++ b/jest.config.js @@ -5,6 +5,7 @@ module.exports = { setupFiles: ['./node_modules/react-native-gesture-handler/jestSetup.js'], setupFilesAfterEnv: [ './jest/setup/setup.ts', + './jest/setup/async-storage.ts', './jest/setup/blur.ts', './jest/setup/carplay.ts', './jest/setup/device-info.js', // JS to prevent Typescript implicit any warning diff --git a/jest/setup/async-storage.ts b/jest/setup/async-storage.ts new file mode 100644 index 00000000..3f147986 --- /dev/null +++ b/jest/setup/async-storage.ts @@ -0,0 +1,3 @@ +jest.mock('@react-native-async-storage/async-storage', () => + require('@react-native-async-storage/async-storage/jest/async-storage-mock'), +)