Detox
Detox copied to clipboard
(WIP) feat(Android): optimize app installation.
Description
Additional fixes on top of the original pr
Resolves https://github.com/wix/Detox/issues/3175 Resolves https://github.com/wix/Detox/issues/2537
Implemented only for Android.
- Improve APK install time by:
- taking a hash of the binary that is being installed and writing it to the emulator as file whose filename is the binary name.
- on the next install, checks whether the hash exists and if it does then clear user data without performing uninstall/install.
- Adds a new method of
resetAppState
to decide between clearing user data and reinstallation. - Adds a boolean option to Detox
behavior
config,optimizeAppInstall
with a corresponding CLI flag:--optimize-app-install
.
In terms of performance: uninstall/install takes 6-7s, whereas clearing app state takes 400-600ms.
This pull request fixes #2534 .
For API changes:
- [X ] I have made the necessary changes in the types index file.