-
Debug APK contents — Androidx libraries include extra text files that Android Studio reads during debugging. We need to make sure these files are preserved for debug builds.
- Create a debug build of the app, e.g.
./gradlew :app:assembleDebug
- View the APK in Android Studio
- Build menu
- Analyze APK
- Open the APK that was built in the first step above
- Verify the APK contains various debug properties and versions files in the root directory and under META-INF/
- Create a debug build of the app, e.g.
-
Release APK contents
- Create a debug build of the app, e.g.
./gradlew :app:assembleRelease
- View the APK in Android Studio
- Build menu
- Analyze APK
- Open the APK that was built in the first step above
- Verify the APK contains various debug properties
- Verify the unzipped directory contains the following:
- AndroidManifest.xml
- assets/
- classes.dex (and perhaps additional classesN.dex)
- compact_formats.proto
- darkside.proto
- google/
- lib/
- META-INF/ (which should only contain a few files)
- res/
- resources.arsc
- service.proto
- Verify the unzipped directory contains the following:
- Create a debug build of the app, e.g.
-
Sanity check release app
- Open
gradle.properties
file and ensure that you have theIS_SIGN_RELEASE_BUILD_WITH_DEBUG_KEY
property set to true. Don't forget to switch the property back to false after this test, so any of your subsequent tests are not affected by it. - Create a release build of the app, e.g.
./gradlew :app:bundleRelease :app:packageZcashmainnetReleaseUniversalApk
. Note these Gradle tasks will create an app bundle, then derive the APK from the app bundle. This more closely matches how the app would be distributed to users through Google Play. - Connect an Android device with developer mode enabled to your computer
- On a computer with the Android developer tools, run
adb logcat
- Install the app on the device, e.g.
adb install -r $pathToUniversalApk
- Run the app
- Verify
- The app launches successfully
- Minimal logs from the app are printed to logcat. Android itself may print logs, but our release build should have logging stripped out
- The app is using mainnet
- Open