Test Your In-App Campaign

You can test your In-App campaigns to see how they will appear and behave for your users. This feature enables you to perform end-to-end tests for all trigger types, ensuring that trigger conditions, audience targeting, and delivery controls work as expected.

Test Your In-App Campaign

To test your campaign, 

  • On the third step of the campaign creation process, click Test Campaign.

Configure Your Test

On the Configure screen, specify the following details:

  1. Target Platform: Select Android as your target platform.
    • Note: This feature currently supports Android devices only.
  2. Unique Identifier: Choose the user attribute to identify the test device (for example, Device ID, Advertising ID). You can select from six different user attributes.



  3. Enter the Unique Identifier: Type the unique identifier for the device where you want to test the in-app campaign.

After you enter these details, click Send Test Campaign. A push notification is sent to your device. Proceed to the next stage to continue testing.

Perform the Test

This stage displays a list of actions to perform to test your campaign. These actions vary based on the trigger you configured during campaign creation:

  • On App Open
  • On Specific Screen
  • On Custom Event

On App Open Trigger

To complete the test, click the push notification. The In-App campaign should appear immediately when you open the app.

After you complete the steps, click View Test Results.

On Specific Screen Trigger

When testing an In-App campaign triggered by a specific screen, an additional step appears under Perform these steps:

Go to screen: The screen you choose

To complete this test, navigate to the selected screen in your app. For example, if you configured the campaign to display on the "Checkout Screen," go to your app's checkout screen.

After viewing the In-App campaign, click View Test Results.

On Custom Event Trigger

When testing an in-app campaign with a custom trigger event, a step appears:

Perform trigger: The trigger you selected

To complete this test, perform the custom event you selected in your app. For example, if your campaign is triggered by an "Add to Cart" event, click the Add to Cart button in your app.

After you complete the steps, click View Test Results.

info

Information

If you do not perform the test steps correctly, the test results will display an error. You must restart the testing process.

Review Test Results

The test results screen shows if your In-App campaign ran successfully:

  • If the Test Results list displays green check marks, your campaign ran successfully. Use your test device to verify that all visual elements of the In-App campaign appear correctly.
  • If the Test Results list displays red crosses, your campaign did not run successfully. The errors are listed under the events. Fix the errors, and then click Re-test to test your campaign again.
    • Click the Re-test button in the bottom-right corner of the pop-up to re-test your In-App campaign.

      Screenshot 2024-03-21 at 1.38.35 PM.png

  • If your campaign trigger was On Custom Event, you also see Perform trigger under Test Results. A green check mark next to Perform trigger indicates that the trigger event was successfully performed, and your test should be successful.
    • Otherwise, a red cross next to Perform trigger indicates an error. An error message provides details about what went wrong.

Common Errors and Resolutions

This table lists common errors you might encounter during testing and their resolutions:

Error Resolution
Push notification not clicked If you do not receive the push notification, restart the test by clicking Re-test and ensure the following configuration steps:
  1. Remove the app from the background.
  2. Activate push notifications. If you are testing on iOS or Android 13 and above, ensure push notifications are enabled.
  3. Add or update your Apple Push Notification service (APNS) certificate if it is missing. For more information, refer here.
  4. Verify user resolution. Ensure the test user exists and a device is attached to this user.
Screen was not visited The campaign configuration has an incorrect screen name, or the screen was not visited during testing. Possible reasons include:
  1. Incorrect screen visited. Navigate to the screen you configured in step 1 of the campaign creation process.
  2. Screen does not exist. Verify with your developer whether the configured screen name is present within the app.
Context not visited The campaign configuration has an incorrect context name, or the context was not visited during testing. Possible reasons include:
  1. Incorrect context visited. Re-test the campaign and navigate to the context you configured in step 1 of the campaign creation process.
  2. Context does not exist. Verify with your developer whether the configured context name is present within the app.
Trigger action not performed The campaign configuration has an incorrect trigger action, or the trigger action was not performed during testing. Possible reasons include:
  1. Custom event trigger action not performed. Re-test the campaign by performing the chosen custom event(s) to trigger the in-app display.
  2. Trigger action performed on an incorrect screen. Execute the chosen custom event on the “{screen_name}” screen to trigger the in-app display.
  3. Trigger action performed on an incorrect context. Execute the chosen custom event on the “{context_name}” context to trigger the in-app display.
  4. Incorrect event attributes. Verify the configured "{attribute_name}" event attribute(s). The attribute may either not exist or be incorrect.
Trigger time not executed The configured trigger time has not been reached. Wait [5 seconds] on the selected screen for the campaign to trigger. Note that a delay time of less than 60 minutes is supported within campaign testing.
Campaign not visible Review the following reasons why your campaign might not be visible, resolve them, and re-test the campaign:
  1. showInApp() method not called on the opened screen: The screen you opened during testing does not have the "showInApp" method. This method is required for the campaign to appear on the screen. Configure it by following the steps mentioned here for Android and here for iOS.
  2. showNudge() method not called on the opened screen: The screen you opened during testing does not have the "showNudge" method. This method is required for the campaign to appear on the screen.
  3. getSelfHandledInApp() method not called on the opened screen: The screen you opened during testing does not have the "getSelfHandledInApp" method. This method is required for the campaign to appear on the screen.
  4. Incorrect nudge position: This nudge campaign was displayed at the wrong position ({nudge_position}). Ensure the correct nudge position is configured in the SDK.
  5. Delivery Errors: Refer to the Delivery Errors section in In-App Campaign Analytics.

Was this article helpful?
0 out of 1 found this helpful

How can we improve this article?