I have a test user account that is working just fine for testing in app purchases.
I would like to “delete” a purchase from this account, so I can test the purchase multiple times. Right now, if I try to purchase, it logically says the the Test User has already purchased the product in question.
Can I delete a purchase from a Test User account so that I can test the same purchase multiple times. I’d hate to have to create a new Test User every time I want to test the purchase.
EDIT: Each time I try to purchase, I get a dialog with “You’ve Already Purchased this. Tap OK to download it again for free”.
If you really want to test it clean, you are going to have to create another test user. However, I don’t see the need for this. Redownloading an in-app purchase is a nearly identical code flow. The actual purchase and verification logic is not part of your application, and a user buying something multiple times is not something that is supposed to happen (unless you specify that it is that kind of consumable). If it works for redownloading, it is safe to assume it will work for the initial purchase.
You do not have access to this data. If Apple exposed a way to reset purchases, they would risk opening themselves up to a security risk since I assume their sandbox server code is practically identical to their production code (otherwise the sandbox would be meaningless). Because the data is on Apple’s servers, associated with an iTunes account, it can span across multiple devices.
An alternate idea would be to delete the in app purchase from your iTunes Connect, and make a new one.