summaryrefslogtreecommitdiff
path: root/test/map
diff options
context:
space:
mode:
authorTobrun <tobrun@mapbox.com>2017-03-24 17:55:55 +0100
committerGitHub <noreply@github.com>2017-03-24 17:55:55 +0100
commit83cef9eb686991d5ba31f89e3fe11cafcb4fd5bf (patch)
tree65ef816b3ff45d68d3e7ab04aca8fa7bebf70005 /test/map
parent80915992ab4e970ca005009ca1175bae24cb448b (diff)
downloadqtlocation-mapboxgl-83cef9eb686991d5ba31f89e3fe11cafcb4fd5bf.tar.gz
[android] - update VectorSource javadoc (#8521)
* [android] - update VectorSource docs on VectorSource creation * [tests] Test only CameraOptions center, zoom in CameraToLatLngBounds
Diffstat (limited to 'test/map')
-rw-r--r--test/map/map.test.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/test/map/map.test.cpp b/test/map/map.test.cpp
index 8f81a5d8c5..b31b4e6ccb 100644
--- a/test/map/map.test.cpp
+++ b/test/map/map.test.cpp
@@ -83,12 +83,11 @@ TEST(Map, CameraToLatLngBounds) {
ASSERT_EQ(bounds, map.latLngBoundsForCamera(camera));
+ // Map::cameraForLatLngBounds only sets zoom and center.
CameraOptions virtualCamera = map.cameraForLatLngBounds(bounds, {});
ASSERT_NEAR(*camera.zoom, *virtualCamera.zoom, 1e-7);
- ASSERT_NEAR(*camera.angle, *virtualCamera.angle, 1e-10);
- ASSERT_NEAR(*camera.pitch, *virtualCamera.pitch, 1e-10);
- ASSERT_NEAR(camera.center->latitude, virtualCamera.center->latitude, 1e-10);
- ASSERT_NEAR(camera.center->longitude, virtualCamera.center->longitude, 1e-10);
+ ASSERT_NEAR(camera.center->latitude, virtualCamera.center->latitude, 1e-7);
+ ASSERT_NEAR(camera.center->longitude, virtualCamera.center->longitude, 1e-7);
}
TEST(Map, Offline) {