Test Plan
The following is a test procedure which allows you to verify that your Rover integration is complete and working.
1. Installation and Initialization
1.1 Validate Correct Token
Using Charles, inspect the network traffic and ensure the proper account token
is being used. You can find this in the x-rover-account-token
header. The
correct value can be found in the Rover Settings app labelled “SDK Token”.
2. Deep Links
Rover deep links use a specific URL scheme assigned to your Rover account. You
can find this in the Rover Settings app
labelled “URL Scheme”. Throughout this section of the test plan we will use
rv-my-app
when constructing example deep links. Any time you see this value
you should replace it with the correct URL scheme for your app.
2.1 Settings Screen Deep Link
Visit rv-my-app://presentSettings
in Safari. It should prompt to open the URL
in your app. The app should open and display the Rover Settings screen.
2.2 Experience Deep Link
Open an Experience in the Rover Experiences app, and click on the chain/link icon on the right side of the grey top bar. In the dialog box to find the experience Deep Link.
Visit the deep link in Safari on the device. It should prompt to open the URL in your app. The app should open and display the experience associated with the URL.
2.3 Notification Center Deep Link
Visit rv-my-app://presentNotificationCenter
in Safari. It should prompt to
open the URL in your app. The app should open and display the Rover Notification
Center.
3. Universal Links
Rover Universal Links use a specific domain assigned to your Rover account. You
can find this in the Rover Settings app
labelled “Associated Domain”. Throughout this section of the test plan we will
use my-app.rover.io
when constructing example Universal Links. Any time you
see this value you should replace it with the correct associated domain for your
app.
3.1 Site Association File
After following the Site
Association
instructions on the Rover developer website, Rover will host an Apple App Site
Association
File
for you. You can access the file at your associated domain and the path expected
by Apple. E.g. https://my-app.rover.io/.well-known/apple-app-site-association
.
View your association file in the browser and ensure the appID
value is
correct as outlined on the Rover developer website.
3.2 Experience Universal Link
Open an Experience in the Rover Experiences app, and click on the chain/link icon on the right side of the grey top bar. In the dialog box to find experience’s Published Web Link.
Visit the link in Safari on the device. It should prompt to open the URL in your app. The app should open and display the experience associated with the URL.
4. Syncing Data
4.1 Foreground Syncing
Ensure your device is connected to Charles and start in the terminated state.
Open the app to initiate the app initialization process. Watch the network
traffic and look for a query to Rover’s GraphQL
API named Sync
. Put the app in the background
and open it again. You should see the same call made again.
4.2 Background Syncing
Send your device a push notification from a Scheduled Notification campaign from
the Rover Campaigns app and ensure the
“Content Available” option is enabled in the Advanced Settings step. Monitor the
network traffic from your device using Charles. When the push is received you
should see a query to Rover’s GraphQL API named
Sync
.
5. Events
5.1 Foreground Flushing
With your device connected to Charles, open your app and wait 30 seconds. You
should see the trackEvents
mutation being called on Rover’s GraphQL
API.
5.2 Background Flushing
With your device connected to Charles, open your app and then immediately close
it. You should see a trackEvents
mutation being called on Rover’s GraphQL
API.
6. Push Notifications
6.1 Push Token
Open the Settings view in your app via the deep link described in 2.1. Take note of your device identifier. Open the Rover Audience app in a browser and find your device. Make sure your device has a valid push token assigned to it.
6.2 Background Push
Create a scheduled notification campaign. With your app in the background, press the Send a Test button and select your test device. Verify the push notification is received.
6.3 Foreground Push
Create a scheduled notification campaign. With your app in the foreground, publish the campaign. Verify the push notification is received.
6.4 Rich Media
Create a scheduled notification campaign. Add an attachment to the notification. press the Send a Test button and select your test device. Verify the push notification is received and the image is attached.
6.5 Foreground Tap Behavior
Create a scheduled notification campaign with the tap behavior set to “Present an experience”. With your app in the foreground, press the Send a Test button and select your test device. Tap the push notification when it is received. Verify the experience is displayed.
6.6 Background Tap Behavior
Create a scheduled notification campaign with the tap behavior set to “Present an experience”. With your app in the background, press the Send a Test button and select your test device. Tap the push notification when it is received. Verify the experience is displayed.
6.7 Terminated Tap Behavior
Create a scheduled notification campaign with the tap behavior set to “Present an experience”. With your app in the terminated state (force quit), press the Send a Test button and select your test device. Tap the push notification when it is received. Verify the experience is displayed.
7. Location
7.1 Location Permissions
Open your app at least once, and ensure that you’ve gone through your user flow where you ask the user to opt into the Location Permission. In the iOS Settings app, navigate to Privacy → Location Services and verify that your app is listed with a value of “Always”.
7.2 Location Sync
Perform a sync with your device connected to Charles. Assuming 4.1 Foreground
Syncing is working correctly, the easiest way to
perform a sync is to just open the app. Watch the network traffic in Charles and
look for a query to Rover’s GraphQL API named
Sync
and ensure that the request contains values for beaconsFirst
and
geofencesFirst
.
7.3 Location Updates
Perform an event flush with your device connected to Charles. Assuming 5.2
Background Flushing is working correctly, the easiest
way to perform an event flush is to put your app in the background. Watch the
network traffic in Charles and look for the trackEvents
mutation. The JSON
payload contains an array of events
. Inspect one or more of the events and
ensure it contains a device.location
property.
When the device’s location updates “significantly” the Rover SDK will capture
the details of the device’s current location and attach it to all events going
forward. Before you can test this functionality you need to trigger a device
location update. The device will usually trigger a location update when it is
first launched from a terminated state however that is not guaranteed. From
Apple engineers we’ve learned that a general rule of thumb is that the device
will trigger a location update whenever the device moves approximately 500
metres. If the device.location
property on your events is null
try “force
quitting” your app and reaping or move a significant distance with your device
and try again.
8. User Info
The User Info section of the Rover documentation explains how you can attach properties about the current user to the device which will show up in the Audience app and can be used for segmentation or personalization.
8.1 Setting User Info
Perform an action in your app which causes your app to set some user info
properties on the Rover SDK. Perform an event flush with your device connected
to Charles. Assuming 5.2 Background Flushing is
working correctly, the easiest way to perform an event flush is to put your app
in the background. Watch the network traffic in Charles and look for the
trackEvents
mutation. The JSON payload contains an array of events
. Inspect
one or more of the events and ensure it contains a device.userInfo
property.
Ensure the value of this property matches the expected user info properties set
by your app.
9. Ticketmaster
9.1 Ticketmaster Sign In
Open the app and sign-in to Ticketmaster through the Presence SDK. After you’ve
signed in, perform a sync with your device connected to Charles. Assuming 4.1
Foreground Syncing is working correctly, the easiest
way to perform a sync is to just open the app. Watch the network traffic in
Charles and look for a query to Rover’s GraphQL
API named Sync
and ensure that the request
contains a value for ticketmasterHostMemberID
or ticketmasterMemberID
.
Ensure the HTTP response body includes a value for data.ticketmaster
.
9.2 Ticketmaster Sign Out
After completing step 9.1, verify that the ticketmaster fields disappear from subsequent sync requests after signing out of ticketmaster in the app.
10. Sync
iOS allows apps to mark themselves as being “Background Fetch” enabled, and the OS will from time to time heuristically wake up the app in the background to perform a sync.
10.1 iOS Background Fetch
With the app deployed to your device through Xcode, select the “Simulate
Background Fetch” option in the “Debug” menu. Monitor the network traffic from
your device using Charles. When the push is received you should see a query to
Rover’s GraphQL API named Sync
.