Test your In-app Billing program

Source: Internet
Author: User

Test your In-app Billing program

To ensure that In-app billing can be used normally in your program, you should test the app before posting it to Google Play. Early testing helps ensure that users are not confused or unresponsive to your purchase process, and that they can see their new purchases in a timely manner.

Using static response Testing

You can test your program in a static manner using the product ID that is reserved on Google Play. When you test a purchase by using a reserved product ID instead of a real product ID, you can use no real payment method or remittance. For more information on what to keep, see testing In-app billing.

Use your own Product ID to test

Because Google play does not allow you to use a developer account to directly purchase an in-store product that you previously created using your developer account, you will need to create an available test account below the developer account. Simply fill out an available Google email address and you can create a test account. Users who have these test accounts can test in-app purchases in apps that you haven't uploaded yet.

Use your own Product ID to test the In-app billing Version 3 app:

      1. In the developer console, add one or more beta accounts to your app's developer account.
        1. Log in to Developer Console using your developer account.
        2. Click Settings > Account Details, then add your beta user's Google email address in the License testing section.
      2. Create a signature apk file for your In-app billing program. How to generate and sign the APK, see Building Your application for Release. Make sure that the certificate and the private Key you signed are the final version, not the debug version.
      3. Make sure you have uploaded the signed apk to the developer console and created the relevant in-app purchases for your application. To test the program, you don't have to publish the program to Google play right now.

        Warning: after you upload your app to the background, Google play may take up to 2-3 hours to confirm your updated APK version (the translator note: It may actually be half an hour to 1 hours). If you test your app before Google Play confirms your uploaded apk, you will receive a "Buy canceled" purchase response, along with an "In-app billing not available in the current version of the program" error message.

      4. Use the ADB to install the APK onto your real test device. Learn how to install applications, see running on a Device. Ensure:

Your test device is running an Android SDK version of 2.2 (API level 8) or higher, and the installed Google Play client version is 3.9.16 or higher.

      1. . You install the program on the Androidmanifest.xml in the android:versionCode and the android:versionName the two attribute values are the same as the values in your developer console apk.

Before installing the program into your device, make sure that the same signature certificate that was uploaded to the apk used on the developer console is the same as the one you want to install.

5. Log in the test device with the tester's account. Buy some items in the program to test your In-app billing program and fix the problems you are experiencing. To learn more about how to test your In-app billing program in a wide range, see Test Purchases (In-app billing Sandbox).

O (∩_∩) o haha ~, the end of the series translation ~ ~ ~

Test your In-app Billing program

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.