Update tests for access token changes
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>MGLMapboxAccessToken</key>
|
||||
<string>pk.eyJ1IjoianVzdGluIiwiYSI6Ik9RX3RRQzAifQ.dmOg_BAp1ywuDZMM7YsXRg</string>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
@@ -34,6 +36,8 @@
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>MGLMapboxMetricsEnabledSettingShownInApp</key>
|
||||
<true/>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
|
||||
@@ -13,8 +13,6 @@
|
||||
wrapper.toolbarHidden = YES;
|
||||
[self.window makeKeyAndVisible];
|
||||
|
||||
[MGLAccountManager setMapboxMetricsEnabledSettingShownInApp:YES]; // a lie, but a convenient one
|
||||
|
||||
return YES;
|
||||
}
|
||||
|
||||
|
||||
@@ -10,8 +10,7 @@
|
||||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
_mapView = [[MGLMapView alloc] initWithFrame:self.view.bounds
|
||||
accessToken:@"pk.eyJ1IjoianVzdGluIiwiYSI6Ik9RX3RRQzAifQ.dmOg_BAp1ywuDZMM7YsXRg"];
|
||||
_mapView = [[MGLMapView alloc] initWithFrame:self.view.bounds];
|
||||
_mapView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
|
||||
|
||||
[self.view addSubview:_mapView];
|
||||
|
||||
@@ -60,12 +60,6 @@
|
||||
XCTAssertEqualObjects([[MGLMapboxEvents sharedManager] appBundleId], @"com.mapbox.Mapbox-GL-Tests");
|
||||
}
|
||||
|
||||
- (void)testTokenSetViaMapView {
|
||||
[tester.mapView setAccessToken:@"test_token"];
|
||||
|
||||
XCTAssertEqualObjects([[MGLMapboxEvents sharedManager] token], @"test_token");
|
||||
}
|
||||
|
||||
- (void)testResumeMetricsCollection {
|
||||
[MGLMapboxEvents resumeMetricsCollection];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user