Cashfree Integrity: How to test in Production Environment

When merchants are trying to install their apps from other than the Play Store and test them in a Production environment then Cashfree mobile SDK (Android, React Native, Flutter, Cordova, Ionic, Capacitor) will block the transaction and the merchant will get the below error.

{
  "message": "com.google.android.packageinstaller is not a trusted source. App should be installed from play store or another whitelisted app store.",
  "code": "installer_package_not_approved",
  "type": "feature_not_enabled"
}

In this case, the SDK will not load the page and the merchant will get an error in the onPaymentFailure Callback. They have to check for an error log.

Below are the sample scenarios when Cashfree Integrity will fail in the PRODUCTION Environment ( In Sandbox, it will always work)

❗️

Info

Trying to directly run from Android Studio/Eclipse or any IDE
Trying to install from Gallery/File Explorer/Google Drive/Slack/Whatsapp or any other link

How to properly test in Production env?

To test in prod, the merchant has to upload their app bundle/APK to the Play Store under an internal testing environment and invite their testing team to test it.

How to do the internal testing setup?

📘

Info

Internal testing is useful to quickly distribute builds to a small set of testers.
This test is used to perform the initial QA checks. You can distribute your application among 100 invited testers. The feedback from your test users won’t affect your app’s public rating it is only visible to the Developer Account.

After publishing the internal test for the first time, it may take few hours for your test link to be available to testers. After that, any new release is available in a few hours. This build is directly available for testing without review.

Create a tester list and share the invitation

  1. Open the Play console and open the Internal testing page under Testing.
  2. Select the Testers tab.
  3. Click on Create email list which opens a popup for adding multiple emails.
  4. Add email addresses separated by commas or click Upload CSV file. If you use a . CSV file, put each email address on its line.
  5. Select Save Changes.
  6. As shown in the below screenshot Copy the link from the Tester tab.
  7. Now share this link with all testers.
  8. Testers have to open this link in Browser where it is logged in with a shared email.
  1. When you open the invitation link in the Browser, you can find this type of invitation information and click on Accept Invitation.

  2. Now the developer can create a release for internal track in the Play console and upload an app bundle that will be available on the Play Store for download for the tester.

Turn on Internal app sharing

If your app has any build in production then these steps are optional but if your app has not live any version yet then this step must be followed by testers.

  1. Open the Google Play Store app Google Play.
  2. Tap Menu Menu > Settings.
  3. In the “About” section, tap the Play Store version 7 times.
  4. After the Internal app sharing setting appears, tap the switch to turn on internal app sharing. Tap Turn on.

Download app

  1. Open the Play Store and make sure the sign-in email is your tester’s email address.
  2. Now search the application on the store.
  3. You can find the application shown with an internal beta label, you can download this application and start testing.
  4. Make sure the Android device has Developer Mode enabled.


Subscribe to Developer Updates


Experience the all-new Cashfree Payments Docs! Faster, smarter, and easier to navigate. Check it out here!🎉