目录

During app testing, you can configure tester accounts on AppGallery Connect and allow these tester accounts to run tests in a sandbox environment. Sandbox testing applies to:

Notice:
Currently, sandbox testing is available only when the app has integrated HMS SDK 3.0 or later and HMS Core (APK) 3.0 or later has been installed on the testing device.

1. Creating a Tester Account

Before app testing, you will need to create a tester account. For details on how to create a tester account, please refer to Managing Tester Accounts.

2. Testing Non-Subscription Payments

You can sign in using a configured tester account, and install the app to be tested. When a request is initiated to purchase a common product (that is, a non-subscription purchase), Huawei IAP detects that the user is a test user, skips the payment step, and displays a message indicating that the payment is successful.Please take note of the following during testing:

3. Testing Subscription Payments

The purchase process of subscriptions is similar to those of other in-app products. The only difference is that subscriptions have more details to consider, such as the subscription renewal result (successful or failed) and renewal period. To help you quickly test the subscription scenario, the subscription renewal in the sandbox testing scenario is faster than that in normal cases. The concept of a "time machine" is introduced. The concept of a "time machine" is only for renewal periods of subscriptions. For example, if the subscription period is one week and the subscription is renewed three minutes later, the validity period of the subscription is extended by one week.

Actual PeriodTest Period
1 week3 minutes
1 month5 minutes
2 months10 minutes
3 months15 minutes
6 months30 minutes
1 year1 hour

Please take note of the following during testing:

Suggestion: Separate the subscription renewal testing in a sandbox from that in an official environment to reduce mutual interference.

4. Testing Game Features

Before a game is released, you can use a tester account to sign in to the game and test the game achievements, leaderboards and saved games. Avoid releasing achievements or leaderboards when the corresponding game is still undergoing tests. This is because achievement or leaderboard data changes along with game operations performed by the tester account, and it cannot be reset once they have been released.

Note that HUAWEI Assistant can display achievements and leaderboards only after your game is released and only on devices running EMUI 9.0 or later and installing HUAWEI Assistant 10.3 or later.