App developers want to thoroughly test the happy path and exceptions in the product experience before shipping to customers. Developers need a way to mock user movement to test their live location features before releasing the app. This involves mocking user location and movement that is as close to real world behavior as possible. Both Android OS & iOS provide APIs and tools to simulate such location data but these tools are insufficient. They provide a stream of locations (latlongs) but do not provide varying activity data, location confidence, and other sensor data that power the awesome features of HyperTrack.
In our previous post (detecting mock locations on Android), we covered the misuse of mock location apps that HyperTrack is able to detect and eliminate. In this post, we cover the HyperTrack feature to generate near-real-world location and activity data to test HyperTrack while standing firmly at your desk sipping a hot cup of joe.
A user’s tracking session starts with HyperTrack.startTracking() and ends with HyperTrack.stopTracking(). In order to mock user movement, developers would call HyperTrack.startMockTracking(callback) and HyperTrack.stopMockTracking() respectively.
HyperTrack.startMockTracking() API starts a simulation from the current location of your device to a nearby place of interest within a 5-10km radius so the session is long enough to test features. The simulation mocks location, activity and other sensor data so that the app can cover near-real-world entropy. This way, developers can test HyperTrack features across the dashboard, widgets, in-app tracking, and web tracking views.
Mock tracking currently covers happy path scenarios only. The next step is to cover exception scenarios and add a high degree of customizability around test scenarios and corner cases. This would include expected events like stopped at a place, started walking, started driving, etc. and unexpected events like location disabled, device switched off, network offline, went off the road, etc. Please use mock tracking extensively and give us your feedback.