What are the conditions to properly test real purchases, when i already have tested my app using test product like
There are few steps that you need to pass, remembering, that some of them need some time to update on Google Play servers.
For this example, let's use
com.example.product as our real product Id. Any time it shows up in this example change it to your own.
You CAN'T test REAL PURCHASES in DEBUG mode. You need to download an app from Beta, so Google know it's ok to make purchases in the app.
Check if you have BILLING permission in
<uses-permission android:name="com.android.vending.BILLING" />
You CAN'T add new product until you have published a beta.
You CAN'T test subscriptions, only products.Now you CAN also test subscriptions (they are renewed every 24h)
Add new productbutton and define new product with
You CAN'T test purchases being signed-in on your device with a developer account. You CAN'T make purchases from yourself.
Google Play Developer Console > APP > BETA
Google Play Developer Console > SETTINGS > LICENSE TESTING- this will make testing purchases enabled for their accounts.
As a tester, you WON'T be charged
When testing from downloaded app Beta, you'll see a testing information on first IAP dialog.
You'll see both your product's name and price set in dev console.
You'll be testing with your real payment options. Don't be scared of seeing your credit card. As i mentioned before - you won't be charged.
When you successfully make a test purchase, you'll get a confirmation e-mail, which looks like a real purchase confirmation.
To repeat the same purchases, you'll need to consume products, cancel purchases, or simply wait 2 weeks until testing purchases will expire.
To cancel purchases: