Skip to content

Add some more details to firebase-appdistribution/test-app/README.md #3930

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

Merged
merged 1 commit into from
Jul 21, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions firebase-appdistribution/test-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,20 +55,22 @@ In-App Feedback is currently tricky to test locally because it relies on the
fact that a release exists with the same hash of the running binary.

To build the debug APK, upload it to App Distribution, and install it on the running emulator:
1. In firebase-appdistribution/test-app/test-app.gradle, uncomment the line `// testers "your email here"` and replace "your email here" with the email you intend to use for testing.
1. Start an emulator
2. Run the following command from the repo's root directory:
1. Run the following command from the repo's root directory:

```
./gradlew :firebase-appdistribution:test-app:build :firebase-appdistribution:test-app:appDistributionUploadDebug && adb install firebase-appdistribution/test-app/build/outputs/apk/debug/test-app-debug.apk
```
./gradlew clean :firebase-appdistribution:test-app:build :firebase-appdistribution:test-app:appDistributionUploadDebug && adb install firebase-appdistribution/test-app/build/outputs/apk/debug/test-app-debug.apk
```

This will build the debug variant of the app (which has the full SDK), upload it to App Distribution, and install it on the running emulator. Run the app in the emulator to test. As an alternative you can always download it using App Distribution, but using `adb` is just faster.

After that, if you want to avoid having to do this every time you want to test
locally:
After that, if you want to avoid having to do this every time you want to test locally:

1. Submit feedback in the locally running app, to generate some logs
2. In the Logcat output, find the release name (i.e. "projects/1095562444941/installations/fCmpB677QTybkwfKbViGI-/releases/3prs96fui9kb0")
3. Modify the body of `ReleaseIdentifier.identifyRelease()` to be:
1. In the Logcat output, find the release name (i.e. `"projects/1095562444941/installations/fCmpB677QTybkwfKbViGI-/releases/3prs96fui9kb0"`)
1. Modify the body of `ReleaseIdentifier.identifyRelease()` to be:

```
return Tasks.forResult("<your release name>");
```
```