summaryrefslogtreecommitdiff
path: root/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift
diff options
context:
space:
mode:
Diffstat (limited to 'platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift')
-rw-r--r--platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift18
1 files changed, 18 insertions, 0 deletions
diff --git a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift
index c3400b1fa2..d33a986beb 100644
--- a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift
+++ b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift
@@ -56,4 +56,22 @@ class MGLMapSnapshotterSwiftTests: MGLMapViewIntegrationTest {
wait(for: [expectation], timeout: timeout)
}
+
+ func testSnapshotOverlaySwiftErgonomics🔒() {
+ let options = MGLMapSnapshotterSwiftTests.snapshotterOptions(size: mapView.bounds.size)
+ let snapshotter = MGLMapSnapshotter(options: options)
+ let expectation = self.expectation(description: "snapshot")
+ expectation.expectedFulfillmentCount = 2
+
+ snapshotter.start(overlayHandler: { (overlay) in
+ guard let _ = overlay.context.makeImage() else {
+ XCTFail()
+ return
+ }
+ expectation.fulfill()
+ }) { (_, _) in
+ expectation.fulfill()
+ }
+ wait(for: [expectation], timeout: 10)
+ }
}