diff options
author | Minh Nguyễn <mxn@1ec5.org> | 2017-01-16 11:38:35 -0800 |
---|---|---|
committer | Minh Nguyễn <mxn@1ec5.org> | 2017-01-16 11:38:35 -0800 |
commit | 7ef2843e6a62116667be6a2c12de085951fdd5ea (patch) | |
tree | 40eca249e044e2706efd1193d617e6eb8e59d708 /platform/darwin/test/MGLFeatureTests.mm | |
parent | 76301b252cbc4bc3ae1fc84322bcbcdbd26cae8a (diff) | |
parent | 13b97dd0cebffe36b187bdb74923910def6bd87b (diff) | |
download | qtlocation-mapboxgl-7ef2843e6a62116667be6a2c12de085951fdd5ea.tar.gz |
Merge branch 'release-ios-v3.4.0' into 1ec5-release-ios-v3.4.0-beta.7
Diffstat (limited to 'platform/darwin/test/MGLFeatureTests.mm')
-rw-r--r-- | platform/darwin/test/MGLFeatureTests.mm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/platform/darwin/test/MGLFeatureTests.mm b/platform/darwin/test/MGLFeatureTests.mm index efc30d307b..91ec9d429e 100644 --- a/platform/darwin/test/MGLFeatureTests.mm +++ b/platform/darwin/test/MGLFeatureTests.mm @@ -322,6 +322,15 @@ @[@(coord2.longitude), @(coord2.latitude)]]} ]}; XCTAssertEqualObjects(geoJSONFeature[@"geometry"], expectedGeometry); + + // When the shape collection is created with an empty array of shapes + shapeCollectionFeature = [MGLShapeCollectionFeature shapeCollectionWithShapes:@[]]; + + // it has the correct (empty) geometry + geoJSONFeature = [shapeCollectionFeature geoJSONDictionary]; + expectedGeometry = @{@"type": @"GeometryCollection", + @"geometries": @[]}; + XCTAssertEqualObjects(geoJSONFeature[@"geometry"], expectedGeometry); } @end |