Test In-App purchase on AdHoc build

Hi,


In the documentation it says you must use a sandbox account when testing In-App purchase using the Sandbox.
But I just noticed that (currently on 10.3 release) the StoreKit popup is saying "Sandbox" even when using a normal account but the app is an AdHoc build.

Is this expected that a normal account also uses the "Sandbox" when running a AdHoc distribution build?


Thanks in advance,

Anders

Yes - the provisioning profile for the ad hoc build is not a 'production' provisioning profile so StoreKit will direct itself to the sandbox. I believe that the sandbox environment can handle a production user ID just as if it were a sandbox test user.


You should expect this behavior - ad hoc is for testing and you don't want to charge people to test your IAP do you?

I'm perfectly happy with this behavior!


I was reading the documents as only the test account will be using the Sandbox.
But I now see:
"If the text “[Environment: Sandbox]” doesn’t appear, you’re using the production environment. Make sure you’re running a development-signed build of your app. Production-signed builds use the production environment."


https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/StoreKitGuide/Chapters/ShowUI.html#//apple_ref/doc/uid/TP40008267-CH3-SW11


Which indicates that adhoc builds always use the sandbox.

Thanks!

@PBK Hello, what about if you have test department which should test subscription workflow? How to test auto-renew subscription on device of testers which use AdHoc build. Also they want to change auto renew subscribe period over appstoreconnect accout, for control time of testing ?)

Test In-App purchase on AdHoc build
 
 
Q