Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,16 @@ @interface FlutterAppDelegateTest : XCTestCase

@implementation FlutterAppDelegateTest

// TODO(dnfield): https://github.com/flutter/flutter/issues/74267
- (void)skip_testLaunchUrl {
- (void)testLaunchUrl {
FlutterAppDelegate* appDelegate = [[FlutterAppDelegate alloc] init];
FlutterViewController* viewController = OCMClassMock([FlutterViewController class]);
FlutterEngine* engine = OCMClassMock([FlutterEngine class]);
FlutterMethodChannel* navigationChannel = OCMClassMock([FlutterMethodChannel class]);
OCMStub([engine navigationChannel]).andReturn(navigationChannel);
OCMStub([viewController engine]).andReturn(engine);
OCMStub([engine waitForFirstFrame:3.0 callback:([OCMArg invokeBlockWithArgs:@(NO), nil])]);
// Set blockNoInvoker to a strong local to retain to end of scope.
id blockNoInvoker = [OCMArg invokeBlockWithArgs:@NO, nil];
OCMStub([engine waitForFirstFrame:3.0 callback:blockNoInvoker]);
appDelegate.rootFlutterViewControllerGetter = ^{
return viewController;
};
Expand All @@ -42,14 +43,16 @@ - (void)skip_testLaunchUrl {
OCMVerify([navigationChannel invokeMethod:@"pushRoute" arguments:@"/custom/route?query=test"]);
}

- (void)skip_testLaunchUrlWithQueryParameterAndFragment {
- (void)testLaunchUrlWithQueryParameterAndFragment {
FlutterAppDelegate* appDelegate = [[FlutterAppDelegate alloc] init];
FlutterViewController* viewController = OCMClassMock([FlutterViewController class]);
FlutterEngine* engine = OCMClassMock([FlutterEngine class]);
FlutterMethodChannel* navigationChannel = OCMClassMock([FlutterMethodChannel class]);
OCMStub([engine navigationChannel]).andReturn(navigationChannel);
OCMStub([viewController engine]).andReturn(engine);
OCMStub([engine waitForFirstFrame:3.0 callback:([OCMArg invokeBlockWithArgs:@(NO), nil])]);
// Set blockNoInvoker to a strong local to retain to end of scope.
id blockNoInvoker = [OCMArg invokeBlockWithArgs:@NO, nil];
OCMStub([engine waitForFirstFrame:3.0 callback:blockNoInvoker]);
appDelegate.rootFlutterViewControllerGetter = ^{
return viewController;
};
Expand All @@ -66,14 +69,16 @@ - (void)skip_testLaunchUrlWithQueryParameterAndFragment {
arguments:@"/custom/route?query=test#fragment"]);
}

- (void)skip_testLaunchUrlWithFragmentNoQueryParameter {
- (void)testLaunchUrlWithFragmentNoQueryParameter {
FlutterAppDelegate* appDelegate = [[FlutterAppDelegate alloc] init];
FlutterViewController* viewController = OCMClassMock([FlutterViewController class]);
FlutterEngine* engine = OCMClassMock([FlutterEngine class]);
FlutterMethodChannel* navigationChannel = OCMClassMock([FlutterMethodChannel class]);
OCMStub([engine navigationChannel]).andReturn(navigationChannel);
OCMStub([viewController engine]).andReturn(engine);
OCMStub([engine waitForFirstFrame:3.0 callback:([OCMArg invokeBlockWithArgs:@(NO), nil])]);
// Set blockNoInvoker to a strong local to retain to end of scope.
id blockNoInvoker = [OCMArg invokeBlockWithArgs:@NO, nil];
OCMStub([engine waitForFirstFrame:3.0 callback:blockNoInvoker]);
appDelegate.rootFlutterViewControllerGetter = ^{
return viewController;
};
Expand Down
12 changes: 6 additions & 6 deletions testing/ios/IosUnitTests/IosUnitTests.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@
0AC232F424BA71D300A85907 /* SemanticsObjectTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = SemanticsObjectTest.mm; sourceTree = "<group>"; };
0AC232F724BA71D300A85907 /* FlutterEngineTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterEngineTest.mm; sourceTree = "<group>"; };
0AC2330324BA71D300A85907 /* accessibility_bridge_test.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = accessibility_bridge_test.mm; sourceTree = "<group>"; };
0AC2330B24BA71D300A85907 /* FlutterTextInputPluginTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FlutterTextInputPluginTest.m; sourceTree = "<group>"; };
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FlutterTextInputPluginTest.m didn't exist.

0AC2330B24BA71D300A85907 /* FlutterTextInputPluginTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterTextInputPluginTest.mm; sourceTree = "<group>"; };
0AC2330F24BA71D300A85907 /* FlutterBinaryMessengerRelayTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterBinaryMessengerRelayTest.mm; sourceTree = "<group>"; };
0AC2331024BA71D300A85907 /* connection_collection_test.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = connection_collection_test.mm; sourceTree = "<group>"; };
0AC2331224BA71D300A85907 /* FlutterEnginePlatformViewTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterEnginePlatformViewTest.mm; sourceTree = "<group>"; };
0AC2331924BA71D300A85907 /* FlutterPluginAppLifeCycleDelegateTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FlutterPluginAppLifeCycleDelegateTest.m; sourceTree = "<group>"; };
0AC2331924BA71D300A85907 /* FlutterPluginAppLifeCycleDelegateTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterPluginAppLifeCycleDelegateTest.mm; sourceTree = "<group>"; };
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FlutterPluginAppLifeCycleDelegateTest.m didn't exist.

0AC2332124BA71D300A85907 /* FlutterViewControllerTest.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = FlutterViewControllerTest.mm; sourceTree = "<group>"; };
0D1CE5D7233430F400E5D880 /* FlutterChannelsTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FlutterChannelsTest.m; sourceTree = "<group>"; };
0D6AB6B122BB05E100EEE540 /* IosUnitTests.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = IosUnitTests.app; sourceTree = BUILT_PRODUCTS_DIR; };
Expand Down Expand Up @@ -90,11 +90,11 @@
0AC232F424BA71D300A85907 /* SemanticsObjectTest.mm */,
0AC232F724BA71D300A85907 /* FlutterEngineTest.mm */,
0AC2330324BA71D300A85907 /* accessibility_bridge_test.mm */,
0AC2330B24BA71D300A85907 /* FlutterTextInputPluginTest.m */,
0AC2330B24BA71D300A85907 /* FlutterTextInputPluginTest.mm */,
0AC2330F24BA71D300A85907 /* FlutterBinaryMessengerRelayTest.mm */,
0AC2331024BA71D300A85907 /* connection_collection_test.mm */,
0AC2331224BA71D300A85907 /* FlutterEnginePlatformViewTest.mm */,
0AC2331924BA71D300A85907 /* FlutterPluginAppLifeCycleDelegateTest.m */,
0AC2331924BA71D300A85907 /* FlutterPluginAppLifeCycleDelegateTest.mm */,
0AC2332124BA71D300A85907 /* FlutterViewControllerTest.mm */,
);
name = Source;
Expand Down Expand Up @@ -209,8 +209,8 @@
0D6AB6A922BB05E100EEE540 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1020;
ORGANIZATIONNAME = "Aaron Clarke";
LastUpgradeCheck = 1300;
ORGANIZATIONNAME = "The Flutter Authors";
TargetAttributes = {
0D6AB6B022BB05E100EEE540 = {
CreatedOnToolsVersion = 10.2.1;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1140"
LastUpgradeVersion = "1300"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down