From b6909748c1b2437b6206f50e48a630ab443969fb Mon Sep 17 00:00:00 2001 From: Jason Wray Date: Wed, 24 Oct 2018 16:07:03 -0400 Subject: [ios, tests] Bump integration tests timeout to 10s --- platform/ios/Integration Tests/MBGLIntegrationTests.m | 2 +- platform/ios/Integration Tests/MGLCameraTransitionTests.mm | 14 +++++++------- .../ios/Integration Tests/MGLStyleLayerIntegrationTests.m | 4 ++-- .../Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift | 2 +- .../Snapshotter Tests/MGLMapSnapshotterTest.m | 10 +++++----- 5 files changed, 16 insertions(+), 16 deletions(-) diff --git a/platform/ios/Integration Tests/MBGLIntegrationTests.m b/platform/ios/Integration Tests/MBGLIntegrationTests.m index 849b6e3dc5..c1a3833fb5 100644 --- a/platform/ios/Integration Tests/MBGLIntegrationTests.m +++ b/platform/ios/Integration Tests/MBGLIntegrationTests.m @@ -8,7 +8,7 @@ #pragma mark - Tests - (void)waitForMapViewToBeRendered { - [self waitForMapViewToBeRenderedWithTimeout:5]; + [self waitForMapViewToBeRenderedWithTimeout:10]; } // This test does not strictly need to be in this test file/target. Including here for convenience. diff --git a/platform/ios/Integration Tests/MGLCameraTransitionTests.mm b/platform/ios/Integration Tests/MGLCameraTransitionTests.mm index 32acf6a1fe..e422c46cf4 100644 --- a/platform/ios/Integration Tests/MGLCameraTransitionTests.mm +++ b/platform/ios/Integration Tests/MGLCameraTransitionTests.mm @@ -34,7 +34,7 @@ [self.mapView setDirection:90 animated:YES]; // loop, render, and wait - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; } @@ -62,7 +62,7 @@ }; [self.mapView setDirection:90 animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; } - (void)testInterruptingAndResetNorthOnlyOnceInIsChanging { @@ -106,7 +106,7 @@ }; [self.mapView setDirection:90 animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; XCTAssertEqualWithAccuracy(self.mapView.direction, 0.0, 0.001, @"Camera should have reset to north. %0.3f", self.mapView.direction); } @@ -222,7 +222,7 @@ // Should take MGLAnimationDuration seconds (0.3) [self.mapView setCenterCoordinate:target zoomLevel:15.0 animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; } - (void)testFlyToCameraInDelegateMethod { @@ -323,7 +323,7 @@ // Should take MGLAnimationDuration [self.mapView setCenterCoordinate:target zoomLevel:zoomLevel animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; NSLog(@"setCenterCoordinate: %0.4fs", stop1 - stop0); NSLog(@"flyToCamera: %0.4fs", stop2 - stop1); @@ -360,7 +360,7 @@ }; [self.mapView setDirection:90 animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; XCTAssertEqualWithAccuracy(self.mapView.direction, 0.0, 0.001, @"Camera should have reset to north. %0.3f", self.mapView.direction); } @@ -386,7 +386,7 @@ }; [self.mapView setCenterCoordinate:CLLocationCoordinate2DMake(40.0, 40.0) animated:YES]; - [self waitForExpectations:@[expectation] timeout:5]; + [self waitForExpectations:@[expectation] timeout:10]; XCTAssertEqualWithAccuracy(self.mapView.direction, 0.0, 0.001, @"Camera should have reset to north. %0.3f", self.mapView.direction); } diff --git a/platform/ios/Integration Tests/MGLStyleLayerIntegrationTests.m b/platform/ios/Integration Tests/MGLStyleLayerIntegrationTests.m index 0cb4461c37..53b8fdd6d1 100644 --- a/platform/ios/Integration Tests/MGLStyleLayerIntegrationTests.m +++ b/platform/ios/Integration Tests/MGLStyleLayerIntegrationTests.m @@ -37,7 +37,7 @@ XCTAssertThrowsSpecificNamed((layer.circleColor = interpExpression), NSException, NSInvalidArgumentException); [self.mapView.style addLayer:layer]; - [self waitForMapViewToBeRenderedWithTimeout:5]; + [self waitForMapViewToBeRenderedWithTimeout:10]; } - (void)testForSteppingExpressionRenderCrashWithEmptyStops { @@ -55,7 +55,7 @@ XCTAssertThrowsSpecificNamed((layer.circleColor = steppingExpression), NSException, NSInvalidArgumentException); [self.mapView.style addLayer:layer]; - [self waitForMapViewToBeRenderedWithTimeout:5]; + [self waitForMapViewToBeRenderedWithTimeout:10]; } @end diff --git a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift index bbdfce7531..0f2034b6b8 100644 --- a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift +++ b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterSwiftTests.swift @@ -22,7 +22,7 @@ class MGLMapSnapshotterSwiftTests: MGLMapViewIntegrationTest { return } - let timeout: TimeInterval = 5.0 + let timeout: TimeInterval = 10.0 let expectation = self.expectation(description: "snapshot") let options = MGLMapSnapshotterSwiftTests.snapshotterOptions(size: mapView.bounds.size) diff --git a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterTest.m b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterTest.m index ca7462f160..32e5fc782d 100644 --- a/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterTest.m +++ b/platform/ios/Integration Tests/Snapshotter Tests/MGLMapSnapshotterTest.m @@ -66,7 +66,7 @@ MGLMapSnapshotter* snapshotterWithCoordinates(CLLocationCoordinate2D coordinates return; } - NSTimeInterval timeout = 5.0; + NSTimeInterval timeout = 10.0; XCTestExpectation *expectation = [self expectationWithDescription:@"snapshot"]; CGSize size = self.mapView.bounds.size; CLLocationCoordinate2D coord = CLLocationCoordinate2DMake(30.0, 30.0); @@ -118,7 +118,7 @@ MGLMapSnapshotter* snapshotterWithCoordinates(CLLocationCoordinate2D coordinates return; } - NSTimeInterval timeout = 5.0; + NSTimeInterval timeout = 10.0; XCTestExpectation *expectation = [self expectationWithDescription:@"snapshot"]; CGSize size = self.mapView.bounds.size; CLLocationCoordinate2D coord = CLLocationCoordinate2DMake(30.0, 30.0); @@ -186,7 +186,7 @@ MGLMapSnapshotter* snapshotterWithCoordinates(CLLocationCoordinate2D coordinates [snapshotter cancel]; - [self waitForExpectations:@[expectation] timeout:0.5]; + [self waitForExpectations:@[expectation] timeout:5.0]; } - (void)testAllocatingSnapshotOnBackgroundQueue { @@ -379,7 +379,7 @@ MGLMapSnapshotter* snapshotterWithCoordinates(CLLocationCoordinate2D coordinates [expectation fulfill]; }]; - [self waitForExpectations:@[expectation] timeout:5.0]; + [self waitForExpectations:@[expectation] timeout:10.0]; } - (void)testSnapshotPointConversionCoordinateOrdering { @@ -426,7 +426,7 @@ MGLMapSnapshotter* snapshotterWithCoordinates(CLLocationCoordinate2D coordinates [expectation fulfill]; }]; - [self waitForExpectations:@[expectation] timeout:5.0]; + [self waitForExpectations:@[expectation] timeout:10.0]; } -- cgit v1.2.1