Testing Your Mobile App

Since the SDK can log conversions generated through the Apple iTunes App Store, Google Play Store, Amazon Appstore for Android, and other third parties, you should test conversion measurement without actually updating your mobile app listing in the production environment. First confirm that the TUNE SDK is successfully working before you update your mobile app in its respective app store. You can save an enormous amount of time, resources, and frustration by first testing that all functions are operational before updating your mobile app for the app store. For Android apps in the Google Play Store, make sure that your app is properly collecting the Install Referrer as described at Testing the Google Play Install Referrer.

Important Note: Before you start testing, first make sure that you integrated the TUNE SDK as described at iOS SDK orAndroid SDK. Then setup a test profile as described in Creating a Test Profile.

After you setup your test profile, generate a measurement URL:

  1. Login to Attribution Analytics.
  2. In the navigation (on the left side), under the Applications section, expand Testing, and then click Test Mobile App.
  3. On the Test Mobile App page, from the drop-down lists for each field (such as Mobile App, Partner,Campaign Type, Destination URL), make the appropriate selections so Attribution Analytics can automatically generate the appropriate measurement URL for your mobile app.
    test_app1
  4. Append the device identifier (that you specified in your test profile) and/or other optional parameters by scrolling down to the Parameters section and opening the Identifiers for App-to-App Attribution accordion menu and add the device identifier. As you type specific parameters to include, the measurement URL below updates and appends these values.test_app2
  5. Select the Test Profile you will be using to perform the test. NOTE: If you have not already done so, please create a test profile.test_app4
  6. To send yourself an email with the updated measurement URL (which now includes your optional parameters), below the Measurement URL box, click the “envelope” icon as shown in the following screenshot. test_app3
  7. In the new email window (that already includes the updated measurement URL in the body of the email), attach your .APK or .IPA file (ad-hoc app build), and then click Send.

 

Before you can install a developer app on an Apple device, first setup a provisioning file as described in Provision an iOS Device. If you use the "TestFlightApp", please visit Testing iOS SDK integration with TestFlightApp.***

For information about generating a measurement URL in production (outside of a test profile), please visit Creating a Measurement URL.

 

The Event Viewer

Before you click and test the measurement URL (in the email that you sent to yourself):

  1. On your test device, start a test session by opening the email that you sent yourself, and then click the measurement URL.
  2. Install the ad-hoc build of your mobile app that you compiled locally (and includes the Attribution Analytics SDK). It is not necessary to install the production version of your mobile app.

Viewing the Click

After you click the measurement URL, check Event Viewer to see the logged click request. It may take up to 30 seconds for the click event to appear. If you do not specify a device identifier when creating your test profile, then Attribution Analytics cannot log the click event and you cannot see it in the Event Viewer.

test-profile-3
 

Include Test Data in Reporting

After you setup a test profile in Attribution Analytics and run a test (for example, perform a mobile app install on your test device), you must include test data in your reports (else you will not see the test install event because by default Attribution Analytics excludes test data from reporting). To include test data in your reports:

  1. In the navigation, under the Reporting section, click the desired type of report (for example, Actuals, Cohort, Retention, or Logs).
  2. On the report page, next to the date time in the upper-left corner, click Edit.
  3. In the parameters and filters panel, scroll down to the Filter section at the bottom, remove the Test Data: Exclude filter, and then click Apply as shown in the following screenshot.IncludeTestDataFilter

 

Viewing the Install/Open/Other Events

After you see the click in Event Viewer, return to the email and install the attached .APK or .IPA file. Install this ad-hoc build since this app is the version that you want to test. After installation, launch the mobile app and proceed to the point where the measureSession and/or measureAction methods are called. After you launch the app, both the install and “app open” events appear in Event Viewer. It may take up to 5 minutes for the events to appear.

event-viewer-New-Page

  When testing your mobile app and using Event Viewer:

  • Do not refresh the page while waiting for the app events to display. Event Viewer displays real-time events and by refreshing your page, you're essentially instructing Event Viewer to start logging a new session of events.
  • The Event Viewer also displays "app open" events (each time you launch the app). Attribution Analytics does not eliminate duplicate events for test profiles (by design), so you also see an install event paired with every "app open" event (which does not indicate that another install occurred). Notice in the previous screenshot that the "app open" and install events have the exact same timestamp.

Testing SDK Implementation

You can use this testing process and functionality to test the Attribution Analytics SDK and ensure that it's implemented appropriately (is logging clicks, installs, and other in-app events accurately). For additional implementation testing and troubleshooting information, please vist Android SDK Implementation Troubleshooting and/or iOS SDK Implementation Troubleshooting.

Have a Question? Please contact support@tune.com for technical support.