diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-17 17:02:12 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-18 09:37:27 +0200 |
commit | cb9b397985b98a75aa9fa5e6f2b135c205f7cafd (patch) | |
tree | 2cd3a2f2ba4e5c8972663313d21a5c81078311d4 /test/ios | |
parent | 711d41f91b41f471c26ff9de6274ab66e0a83176 (diff) | |
download | qtlocation-mapboxgl-cb9b397985b98a75aa9fa5e6f2b135c205f7cafd.tar.gz |
[core] Fix LatLngBounds default coordinates
LatLngBounds southwest and northeast coordinate points were inverted, so
they could be extended via LatLngBounds::extend(). However, this looks
confusing and error-prone.
A static LatLngBounds::getExtendable() is added to address cases when we
want to extend LatLngBounds.
Diffstat (limited to 'test/ios')
-rw-r--r-- | test/ios/MapViewTests.m | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/ios/MapViewTests.m b/test/ios/MapViewTests.m index a97f2d817b..01c2beafe2 100644 --- a/test/ios/MapViewTests.m +++ b/test/ios/MapViewTests.m @@ -317,12 +317,14 @@ const NSTimeInterval MGLAnimationDurationOverDefault = MGLAnimationDurationDefau tester.mapView.centerCoordinate = newCenterCoordinate; - XCTAssertEqual(tester.mapView.centerCoordinate.latitude, + XCTAssertEqualWithAccuracy(tester.mapView.centerCoordinate.latitude, newCenterCoordinate.latitude, + 0.001, @"setting center should change latitude"); - XCTAssertEqual(tester.mapView.centerCoordinate.longitude, + XCTAssertEqualWithAccuracy(tester.mapView.centerCoordinate.longitude, newCenterCoordinate.longitude, + 0.001, @"setting center should change longitude"); } |