public void Create() { Utilities.Web.Google.StaticMaps.Map TestMap = new Utilities.Web.Google.StaticMaps.Map(); TestMap.Center = new Address() { PhysicalAddress = "123 Somewhere St. Detroit, MI" }; TestMap.Format = ImageFormat.JPG; TestMap.Key = "12345678"; TestMap.MapType = MapType.Hybrid; Markers MarkerSet = new Markers(); MarkerSet.Color = "0x00FF00"; MarkerSet.Size = MarkerSize.Tiny; MarkerSet.MarkerList.Add(new LongLat() { Longitude = 1.03123, Latitude = 2.03123 }); MarkerSet.MarkerList.Add(new Address() { PhysicalAddress = "123 Somewhere St. Detroit, MI" }); TestMap.Markers.Add(MarkerSet); TestMap.Sensor = false; TestMap.UseHTTPS = true; Assert.Equal("https://maps.googleapis.com/maps/api/staticmap?sensor=false¢er=123+Somewhere+St.+Detroit%2c+MI&zoom=12&size=100x100&scale=1&format=jpg&maptypehybrid&markers%3dsize%3atiny%7ccolor%3a0x00FF00%7c2.03123%2c1.03123%7c123+Somewhere+St.+Detroit%2c+MI&key=12345678", TestMap.ToString()); }
public void Create() { Utilities.Web.Google.StaticMaps.Map TestMap = new Utilities.Web.Google.StaticMaps.Map(); TestMap.Center = new Address(){PhysicalAddress="123 Somewhere St. Detroit, MI"}; TestMap.Format = ImageFormat.JPG; TestMap.Key = "12345678"; TestMap.MapType = MapType.Hybrid; Markers MarkerSet=new Markers(); MarkerSet.Color="0x00FF00"; MarkerSet.Size=MarkerSize.Tiny; MarkerSet.MarkerList.Add(new LongLat(){Longitude=1.03123,Latitude=2.03123}); MarkerSet.MarkerList.Add(new Address(){PhysicalAddress="123 Somewhere St. Detroit, MI"}); TestMap.Markers.Add(MarkerSet); TestMap.Sensor = false; TestMap.UseHTTPS = true; Assert.Equal("https://maps.googleapis.com/maps/api/staticmap?sensor=false¢er=123+Somewhere+St.+Detroit%2c+MI&zoom=12&size=100x100&scale=1&format=jpg&maptypehybrid&markers%3dsize%3atiny%7ccolor%3a0x00FF00%7c2.03123%2c1.03123%7c123+Somewhere+St.+Detroit%2c+MI&key=12345678", TestMap.ToString()); }