0
    	setMockLocation(15.387653, 73.872585, 500); 
    } 
     
    private void setMockLocation(double latitude, double longitude, float accuracy) {
    	 
        lm.addTestProvider (LocationManager.GPS_PROVIDER,
                            "requiresNetwork" == "", 
                            "requiresSatellite" == "", 
                            "requiresCell" == "", 
                            "hasMonetaryCost" == "", 
                            "supportsAltitude" == "", 
                            "supportsSpeed" == "", 
                            "supportsBearing" == "", 
                             android.location.Criteria.POWER_LOW,
                             android.location.Criteria.ACCURACY_FINE);      
 
        Location newLocation = new Location(LocationManager.GPS_PROVIDER);
 
        newLocation.setLatitude(latitude);
        newLocation.setLongitude(longitude);
        newLocation.setAccuracy(accuracy);
 
        lm.setTestProviderEnabled(LocationManager.GPS_PROVIDER, true);
 
        lm.setTestProviderStatus(LocationManager.GPS_PROVIDER,
                                 LocationProvider.AVAILABLE,
                                 null,System.currentTimeMillis());    
       
        lm.setTestProviderLocation(LocationManager.GPS_PROVIDER, newLocation);      
 
    } 
 
}