From c117a411ae7a66f830b0987f808ebb24bbaf22ef Mon Sep 17 00:00:00 2001 From: Chris Bracken Date: Thu, 10 Sep 2020 22:57:56 -0700 Subject: [PATCH] Re-enable (most) iOS Scenarios tests (flutter/engine#21087) This re-enables the iOS Scenarios tests which have been flaky in the last couple days. Disabling two tests where we've seen the flakes: * AppLifecycleTests testFlutterViewControllerDetachingSendsApplicationLifecycle * FlutterViewControllerInitialRouteTest testSettingInitialRoute This reverts commit 84995bd516d94a3a7e52e752ad666a8b22068498. --- .../ScenariosTests/AppLifecycleTests.m | 4 +++- .../FlutterViewControllerInitialRouteTest.m | 4 +++- .../testing/scenario_app/run_ios_tests.sh | 17 ++++++----------- 3 files changed, 12 insertions(+), 13 deletions(-) diff --git a/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/AppLifecycleTests.m b/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/AppLifecycleTests.m index b2bf497cf36..3efa1741312 100644 --- a/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/AppLifecycleTests.m +++ b/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/AppLifecycleTests.m @@ -227,7 +227,9 @@ FLUTTER_ASSERT_ARC [engine setViewController:nil]; } -- (void)testFlutterViewControllerDetachingSendsApplicationLifecycle { +// TODO(cbracken): re-enable this test by removing the skip_ prefix once the source of its flakiness +// has been identified. https://github.com/flutter/flutter/issues/61620 +- (void)skip_testFlutterViewControllerDetachingSendsApplicationLifecycle { XCTestExpectation* engineStartedExpectation = [self expectationWithDescription:@"Engine started"]; // Let the engine finish booting (at the end of which the channels are properly set-up) before diff --git a/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/FlutterViewControllerInitialRouteTest.m b/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/FlutterViewControllerInitialRouteTest.m index baf9ad34419..155430c8155 100644 --- a/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/FlutterViewControllerInitialRouteTest.m +++ b/engine/src/flutter/testing/scenario_app/ios/Scenarios/ScenariosTests/FlutterViewControllerInitialRouteTest.m @@ -33,7 +33,9 @@ FLUTTER_ASSERT_ARC [super tearDown]; } -- (void)testSettingInitialRoute { +// TODO(cbracken): re-enable this test by removing the skip_ prefix once the source of its flakiness +// has been identified. https://github.com/flutter/flutter/issues/61620 +- (void)skip_testSettingInitialRoute { self.flutterViewController = [[FlutterViewController alloc] initWithProject:nil initialRoute:@"myCustomInitialRoute" diff --git a/engine/src/flutter/testing/scenario_app/run_ios_tests.sh b/engine/src/flutter/testing/scenario_app/run_ios_tests.sh index 351b2c0e7e4..225f88e977f 100755 --- a/engine/src/flutter/testing/scenario_app/run_ios_tests.sh +++ b/engine/src/flutter/testing/scenario_app/run_ios_tests.sh @@ -33,14 +33,9 @@ if [[ $# -eq 1 ]]; then FLUTTER_ENGINE="$1" fi -echo "iOS Scenarios tests currently disabled due to flakiness" -echo "See: https://github.com/flutter/flutter/issues/61620" - -# TODO(cbracken): re-enable when -# https://github.com/flutter/flutter/issues/61620 is fixed. -# cd ios/Scenarios -# set -o pipefail && xcodebuild -sdk iphonesimulator \ -# -scheme Scenarios \ -# -destination 'platform=iOS Simulator,name=iPhone 8' \ -# test \ -# FLUTTER_ENGINE="$FLUTTER_ENGINE" +cd ios/Scenarios +set -o pipefail && xcodebuild -sdk iphonesimulator \ + -scheme Scenarios \ + -destination 'platform=iOS Simulator,name=iPhone 8' \ + test \ + FLUTTER_ENGINE="$FLUTTER_ENGINE"