@@ -377,3 +377,48 @@ def test_bing_map_url_multiple_props_and_long_lat_provided():
377
377
378
378
loc_url = loc .to_maps_url ("Bing Maps" )
379
379
assert loc_url == expected_url
380
+
381
+
382
+ def test_bing_map_url_for_0_long_lat ():
383
+ expected_url = "https://bing.com/maps/default.aspx?where1=0.0%2C0.0&lvl=16"
384
+
385
+ loc = stix2 .v21 .Location (
386
+ region = "Gulf of Guinea" ,
387
+ country = "International waters" ,
388
+ street_address = "0°N, 0°E – Null Island" ,
389
+ latitude = 0.0 ,
390
+ longitude = 0.0 ,
391
+ )
392
+
393
+ loc_url = loc .to_maps_url ("Bing Maps" )
394
+ assert loc_url == expected_url
395
+
396
+
397
+ def test_bing_map_url_for_0_long ():
398
+ expected_url = "https://bing.com/maps/default.aspx?where1=0.0%2C39.668&lvl=16"
399
+
400
+ loc = stix2 .v21 .Location (
401
+ region = "Eastern Africa" ,
402
+ country = "Kenya" ,
403
+ street_address = "0°N, 39.668°E" ,
404
+ latitude = 0.0 ,
405
+ longitude = 39.668 ,
406
+ )
407
+
408
+ loc_url = loc .to_maps_url ("Bing Maps" )
409
+ assert loc_url == expected_url
410
+
411
+
412
+ def test_bing_map_url_for_0_lat ():
413
+ expected_url = "https://bing.com/maps/default.aspx?where1=51.477%2C0.0&lvl=16"
414
+
415
+ loc = stix2 .v21 .Location (
416
+ region = "Western Europe" ,
417
+ country = "United Kingdom" ,
418
+ street_address = "Royal Observatory, Blackheath Ave, Greenwich, London SE10 8XJ, United Kingdom" ,
419
+ latitude = 51.477 ,
420
+ longitude = 0.0 ,
421
+ )
422
+
423
+ loc_url = loc .to_maps_url ("Bing Maps" )
424
+ assert loc_url == expected_url
0 commit comments