Files
MapLibreParticleLab/platform/ios/test/MGLAnnotationViewIntegrationTests.swift
Jesse Bounds fce7747da0 [ios] Fix annotation initializers for subclasses of MGLAnnotationView (#9104)
Use a common init function in both of the provided initializers so that subclasses of `MGLAnnotationView` written in Swift don't need to override `init(annotation, reuseIdentifier)`
2017-05-24 21:08:19 -07:00

24 lines
538 B
Swift

import XCTest
import Mapbox
class CustomAnnotationView: MGLAnnotationView {
override init(reuseIdentifier: String?) {
super.init(reuseIdentifier: reuseIdentifier)
}
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
}
}
class MGLAnnotationViewIntegrationTests: XCTestCase {
func testCreatingCustomAnnotationView() {
let customAnnotationView = CustomAnnotationView(reuseIdentifier: "resuse-id")
XCTAssertNotNil(customAnnotationView)
}
}