Paul
Paul

Reputation: 6176

How to use test account on Google Play? GooglePlay always sees me as the purchaser

I added a gmail account in the test input (in the Developer Console), I added my apk on my device, and I changed the account in GooglePlay app. But I always get the same error : "the purchaser cannot buy this item" as if I was using my developer account to test the purchase, which is not allowed. Does someone know how to test the app with the test user account?

Thanks

Upvotes: 3

Views: 15964

Answers (1)

Ted Hopp
Ted Hopp

Reputation: 234847

You have to set your account on the device (not just in the Google Play app) to your test account. Then you have to make sure that your test account is registered in your developer console (which you open using your publisher account). The most flexible approach is to set up a Google group and add that to the developer console, then accept your test account into the group.

EDIT: Here are the steps I use when testing an app that has Google licensing. It's all pretty much as described in the section Setting Up the Testing Environment of the documentation for setting up licensing.

  • Upload the .apk to my account on Google Play. To test an upcoming release of an existing app, the .apk file with the new version code needs to be uploaded (but need not be published).
  • Side-load the .apk onto my device.
  • Make sure that the account on the device is either my publisher account or an account that I have registered the account to have testing access (this is found under "Setting" -> "Account Details" on the developer console).
  • Set the Licensed Test Response to whatever I need for testing.
  • Run the app on the device. It should receive the test response when it contacts the licensing server.

Note that all this is different from setting up Alpha and Beta testers. The details for that are described here. This testing program is a different facility provided by Google where you actually publish alpha and/or beta .apk files, send invitations to users to opt-in as testers, and they access the test versions of the apps through Google Play. For that program, my understanding is that the publisher account cannot also be a tester account. Note that there are several caveats when using this program:

  • Alpha- or beta-test apps will only appear in Google Play for testers that opt-in and not to any other users.
  • A production APK is not required to publish an alpha- or beta-test app.
  • It may take up to 24 hours after publishing for the test link to become active.

Upvotes: 7

Related Questions