diff options
author | Julian Rex <julian.rex@gmail.com> | 2018-09-05 11:53:12 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-05 11:53:12 -0400 |
commit | 315a9e3cdfef828da9d359209ce367d0d2b3ebe8 (patch) | |
tree | c7d374a515989d4c1f388c68879ed7b44748375d /platform/ios/Integration Tests/MGLMapViewIntegrationTest.m | |
parent | 5aca8e9ffbc90e9b431869e616f8451b09c352ef (diff) | |
download | qtlocation-mapboxgl-315a9e3cdfef828da9d359209ce367d0d2b3ebe8.tar.gz |
[ios, macos] Call snapshotter (Obj-C) completion block on dealloc/cancel if snapshot hasn't finished. (#12355)
Diffstat (limited to 'platform/ios/Integration Tests/MGLMapViewIntegrationTest.m')
-rw-r--r-- | platform/ios/Integration Tests/MGLMapViewIntegrationTest.m | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/platform/ios/Integration Tests/MGLMapViewIntegrationTest.m b/platform/ios/Integration Tests/MGLMapViewIntegrationTest.m index f67150ba9b..68023f3556 100644 --- a/platform/ios/Integration Tests/MGLMapViewIntegrationTest.m +++ b/platform/ios/Integration Tests/MGLMapViewIntegrationTest.m @@ -6,6 +6,17 @@ @implementation MGLMapViewIntegrationTest +- (NSString*)validAccessToken { + NSString *accessToken = [[NSProcessInfo processInfo] environment][@"MAPBOX_ACCESS_TOKEN"]; + if (!accessToken) { + printf("warning: MAPBOX_ACCESS_TOKEN env var is required for this test - skipping.\n"); + return nil; + } + + [MGLAccountManager setAccessToken:accessToken]; + return accessToken; +} + - (void)setUp { [super setUp]; |