Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to test my application for gps location without travelling in real time ?

Problem behind my query :

I am in need to test a travel based application where your location will change according to the travelers direction, now i need to test my geo location based app while on the drive (a car/some vehicle)

Question As location dynamically changes on the move,is it there any way to test the application for testing/simulate without travelling in a real time?

share|improve this question
Would… be relevant to your problem? – Toby Jackson Jan 3 '14 at 15:33
For what mobile platform do you need solution? – Dmitry Cheremushkin Jun 17 '14 at 21:55
@Dmitry.Cheremushkin android or ios would be better friend – BlueBerry - Vignesh4303 Jun 18 '14 at 9:43
For Android: Lockito app should work (see my answer below). For iOS don't know yet. – Dmitry Cheremushkin Jun 18 '14 at 10:00
I've updated my answer with 2 approaches for iOS. Accept it if it's enough info. ;) – Dmitry Cheremushkin Jun 19 '14 at 5:53
up vote 3 down vote accepted

• For Android

Lockito application should work for you.

It allows to emulate movement from one location to another one.
You can set the speed, the route is based on Google Maps.

• For iOS

There are at least 2 approaches:

  • use Xcode with GPX files
    Here's good article on this. Also there is a script to generate GPX files with routes.

  • or add location spoofing to your test scripts
    Find information and code example here. Using this you can set moving speed as well.

share|improve this answer
You really need to give more information - how does this software help the OP test their software's geolocation function without having to travel? – Kate Paulk Jun 5 '14 at 10:07
While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. – Kate Paulk Jun 5 '14 at 10:10
Welcome to SQA, Dmitry! I'd like to give you a chance to elaborate on this. As it stands, it's impossible to make the connection of why it's a good tool based on just what is in the answer. If you could flesh out your thoughts here, that'd be great! =) – corsiKa Jun 5 '14 at 14:07
Good improvement, that's a much better answer. Thanks Dmitry! – testerab Jun 7 '14 at 6:54

You could to create a Test-specific build which stubs the input GPS data. By having a data-input interface (in code) you could have fake GPS information fed in - I'm not sure what the data is or how it will look, but whoever developed the application should be able to engineer this.

While this is going to be a build which is never to be released to production it will allow you to gain some confidence in the gps coordinate functionality quickly and easily, without leaving your seat.

Occasionally - at least once - during an Integration stage the actual GPS-mapping (non-stubbed) will also require actual testing.

share|improve this answer

We'll need more information to have a better answer.

In the meanwhile here are some options-

  1. Buy a GPS simulator. It costs a few 10K's$ but will solve your problems since it generates "real" GPS signal. As a bonus it will also test your GPS receiver, and your application with non-ideal GPS conditions.

  2. Feed the application faked coordinated (see kiwimatt reply). for example by injecting NMEA messages or other messages at the driver level (GPS chip -> HW interface -> SW interface -> driver ->[insert messages here]-> application).

You can generate coordinates along a route by taking a GPS receiver to a drive (there are cheap USB GPS dongles you can plug to a laptop, or cheap standalone receivers communicating by Bluetooth).

share|improve this answer

This sounds like the perfect scenario for a test stub. You should look into what actual data the application will process (NMEA stream, real time GPS feed, KML file etc). Once you understand the model, you will need to record or generate a test file that matches what you want to test, and then inject it into the application via the test stub.

share|improve this answer

While testing location based app I used to travel to get exact results. But I used another way also by using the other Android apps that gives Fake GPS locations. By using fake GPS locations you can test your app.

share|improve this answer
fake location apps will just help u to simulate current location ,but i need to test for start and end points without travelling in real time,for e.g let me say i am travelling a distance of 450kms,my application would automatically changes location based on ur move,how to test this scenario without travelling is my question – BlueBerry - Vignesh4303 Jan 3 '14 at 6:59

For Android & iOS :

You can refer this blog, it contains practical result to your queries

share|improve this answer
Hello Nishant. I really really like this link. Would you mind editing your answer in order to contain some useful information in case it turns into a dead link? – Paul Muir Dec 16 '14 at 18:51

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.