I am trying to integrate the in-app review library from Android, as described in the following link.
https://developer.android.com/guide/playcore/in-app-review/kotlin-java
From this link, I am using the following code.
private void showRatingUserInterface(final Activity activity) {
final ReviewManager manager = ReviewManagerFactory.create(activity);
Task<ReviewInfo> request = manager.requestReviewFlow();
request.addOnCompleteListener(new OnCompleteListener<ReviewInfo>() {
@Override
public void onComplete(@NonNull Task<ReviewInfo> task) {
if (task.isSuccessful()) {
ReviewInfo reviewInfo = task.getResult();
Task<Void> flow = manager.launchReviewFlow(activity, reviewInfo);
flow.addOnCompleteListener(new OnCompleteListener<Void>() {
@Override
public void onComplete(@NonNull Task<Void> task2) {
// do nothing
}
});
}
}
});
}
Android also describes how to test the in-app review library, as shown in the following link.
https://developer.android.com/guide/playcore/in-app-review/test
I followed the guidelines from the links above, however, the in-app review interface is never launched. In more detail, I've performed the following actions.
- Added play core dependency version 1.8.0 to the build.gradle file.
- Released an internal test of my app in the Google Play Console, including the code shown here above. This function is called when my game is finished.
- Cleared review in the Play Store of this application from my test account.
- Downloaded my app from the Play Store with my test account.
Has anyone an idea what goes wrong here?