If your application takes advantage of In App Purchase, you must set up an in app purchase test user in iTunes Connect. To do so, log in, access the Manage Users module, select the In App Purchase Test User section, then follow these steps:
Enter an email address for the test account that's not associated with any other Apple account. (You'll use this email address and password to confirm a purchase during your testing).
Before you test, go to the Store settings (in the Settings App) on your device and touch Sign Out to prevent a non-test account from automatically being used during testing. (IMPORTANT: Do not enter your test account information in the Store settings panel. Doing so could invalidate your test account.)
Connect your device to your development workstation and select it as the Active SDK. (The Store Kit APIs are not available when testing in the iPhone Simulator.) When your application requests a payment, confirm, and select Use Existing Account to enter your test account username and password to complete the test. No financial transaction takes place as no credit card number was involved, but a complete transaction is generated which includes a receipt.
Please note, each in app purchase test user can only be tied to one iTunes Store territory, and test user accounts must be new, unique Apple accounts. You cannot reuse existing Apple accounts to set up an in app purchase test user account.