public void TestCoordinates() { foreach (var location in locationDictionary) { CheckCoords(geocodingService.GetLocationFromStringQuery(location.Key), location.Value) .Should() .BeTrue("service should return proper geographical data."); } }
private async void CalculateRoute() { var from = await GeocodeAddress(From); var to = await GeocodeAddress(To); if (from == null) { return; } if (DirectionsMap.Children.Count > 4) { DirectionsMap.Children.RemoveAt(DirectionsMap.Children.Count - 1); } var p = geocodingService.GetLocationFromStringQuery(this.From); DirectionsMap.Children.Add(new Pushpin { Location = p }); CalculateRoute(from, to); }