In short, the read in app purchase information is succeeding and giving the same info through BreakInAppPurchaseProductInfo wether the product has been bought or not.
- Set an in app product, non consumable (like a product meant to remove ads).
- Set a tester with license testing enabled in android in google play console, so you can test payments for in app purchases.
- Set the behaviour in google play console to RESPOND_NORMALLY in the license test response.
- Test the method, you will receive success and then print the all the info with BreakInAppPurchaseProductInfo. You will receive an empty transaction identifier and an empty Receipt data, but you will receive some other data like price and so on.
- Buy the game.
- Test the method again…you will receive, the EXACT same info than in point 4, so you cannot distinguish wether the product has been bought or not!. Yes, you can store some preferences, but that doesn’t work if you :
- Return the product (bought by mistake etc…)
- Test the method again… and you will receive a success with the, again, same info.
So, what happens when you install the game in a new device? I have no way to know the product is purchased other than trying to purchase it again (in wich case I receive an “alreadyOwned”.
This is not a big problem but certainly is an unexpected and buggy behaviour.
Any clue how to distinguish if an in app purchase of non-consumable item has been bought or not?