summaryrefslogtreecommitdiff
path: root/platform/darwin/test/MGLShapeSourceTests.mm
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-08-10 14:45:57 +0300
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-08-21 11:58:56 +0300
commite0e5dbb161a105a40b9f0d88c6625f05ab54e106 (patch)
treea924a6466c0d0bf14a1442a3db95ef282bc91a26 /platform/darwin/test/MGLShapeSourceTests.mm
parent112bbc7ab289298094d6e6593437a71ec8029caa (diff)
downloadqtlocation-mapboxgl-e0e5dbb161a105a40b9f0d88c6625f05ab54e106.tar.gz
[ios, macos] Introduce `MGLShapeSourceOptionLineDistanceMetrics`upstream/MGLShapeSourceOptionLineDistanceMetrics
Exposes access to https://www.mapbox.com/mapbox-gl-js/style-spec/#sources-geojson-lineMetrics
Diffstat (limited to 'platform/darwin/test/MGLShapeSourceTests.mm')
-rw-r--r--platform/darwin/test/MGLShapeSourceTests.mm4
1 files changed, 3 insertions, 1 deletions
diff --git a/platform/darwin/test/MGLShapeSourceTests.mm b/platform/darwin/test/MGLShapeSourceTests.mm
index d3f9a599e2..c4f791f958 100644
--- a/platform/darwin/test/MGLShapeSourceTests.mm
+++ b/platform/darwin/test/MGLShapeSourceTests.mm
@@ -18,7 +18,8 @@
MGLShapeSourceOptionMaximumZoomLevelForClustering: @98,
MGLShapeSourceOptionMaximumZoomLevel: @99,
MGLShapeSourceOptionBuffer: @1976,
- MGLShapeSourceOptionSimplificationTolerance: @0.42};
+ MGLShapeSourceOptionSimplificationTolerance: @0.42,
+ MGLShapeSourceOptionLineDistanceMetrics: @YES};
auto mbglOptions = MGLGeoJSONOptionsFromDictionary(options);
XCTAssertTrue(mbglOptions.cluster);
@@ -27,6 +28,7 @@
XCTAssertEqual(mbglOptions.maxzoom, 99);
XCTAssertEqual(mbglOptions.buffer, 1976);
XCTAssertEqual(mbglOptions.tolerance, 0.42);
+ XCTAssertTrue(mbglOptions.lineMetrics);
options = @{MGLShapeSourceOptionClustered: @"number 1"};
XCTAssertThrows(MGLGeoJSONOptionsFromDictionary(options));