<% const type = locals.type; const layoutProperties = locals.layoutProperties; const paintProperties = locals.paintProperties; -%> // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. #import "MGLStyleLayerTests.h" @interface MGL<%- camelize(type) %>LayerTests : MGLStyleLayerTests @end @implementation MGL<%- camelize(type) %>LayerTests - (void)test<%- camelize(type) %>Layer { NSString *filePath = [[NSBundle bundleForClass:self.class] pathForResource:@"amsterdam" ofType:@"geojson"]; NSURL *url = [NSURL fileURLWithPath:filePath]; MGLGeoJSONSource *source = [[MGLGeoJSONSource alloc] initWithSourceIdentifier:@"sourceID" URL:url]; MGL<%- camelize(type) %>StyleLayer *layer = [[MGL<%- camelize(type) %>StyleLayer alloc] initWithLayerIdentifier:@"layerID" sourceIdentifier:@"sourceID"]; [self.mapView.style addSource:source]; [self.mapView.style addLayer:layer]; <% for (const property of layoutProperties) { -%> <%- testImplementation(property, type) %> <% } -%> <% for (const property of paintProperties) { -%> <%- testImplementation(property, type) %> <% } -%> MGL<%- camelize(type) %>StyleLayer *gLayer = [self.mapView.style layerWithIdentifier:@"layerID"]; <% for (const property of layoutProperties) { -%> <%- testGetterImplementation(property, type) %> <% } -%> <% for (const property of paintProperties) { -%> <%- testGetterImplementation(property, type) %> <% } -%> } @end