@@ -22,8 +22,7 @@ - (void)testPluginPickImageDeviceBack {
2222 if (![UIImagePickerController isSourceTypeAvailable: UIImagePickerControllerSourceTypeCamera]) {
2323 return ;
2424 }
25- FLTImagePickerPlugin *plugin =
26- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
25+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
2726 FlutterMethodCall *call =
2827 [FlutterMethodCall methodCallWithMethodName: @" pickImage"
2928 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(0 )}];
@@ -38,8 +37,7 @@ - (void)testPluginPickImageDeviceFront {
3837 if (![UIImagePickerController isSourceTypeAvailable: UIImagePickerControllerSourceTypeCamera]) {
3938 return ;
4039 }
41- FLTImagePickerPlugin *plugin =
42- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
40+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
4341 FlutterMethodCall *call =
4442 [FlutterMethodCall methodCallWithMethodName: @" pickImage"
4543 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(1 )}];
@@ -54,8 +52,7 @@ - (void)testPluginPickVideoDeviceBack {
5452 if (![UIImagePickerController isSourceTypeAvailable: UIImagePickerControllerSourceTypeCamera]) {
5553 return ;
5654 }
57- FLTImagePickerPlugin *plugin =
58- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
55+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
5956 FlutterMethodCall *call =
6057 [FlutterMethodCall methodCallWithMethodName: @" pickVideo"
6158 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(0 )}];
@@ -70,8 +67,7 @@ - (void)testPluginPickVideoDeviceFront {
7067 if (![UIImagePickerController isSourceTypeAvailable: UIImagePickerControllerSourceTypeCamera]) {
7168 return ;
7269 }
73- FLTImagePickerPlugin *plugin =
74- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
70+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
7571 FlutterMethodCall *call =
7672 [FlutterMethodCall methodCallWithMethodName: @" pickVideo"
7773 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(1 )}];
@@ -84,8 +80,7 @@ - (void)testPluginPickVideoDeviceFront {
8480
8581#pragma mark - Test video duration
8682- (void )testPickingVideoWithDuration {
87- FLTImagePickerPlugin *plugin =
88- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
83+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
8984 FlutterMethodCall *call = [FlutterMethodCall
9085 methodCallWithMethodName: @" pickVideo"
9186 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(0 ), @" maxDuration" : @95 }];
@@ -96,8 +91,7 @@ - (void)testPickingVideoWithDuration {
9691}
9792
9893- (void )testPluginPickImageSelectMultipleTimes {
99- FLTImagePickerPlugin *plugin =
100- [[FLTImagePickerPlugin alloc ] initWithViewController: [UIViewController new ]];
94+ FLTImagePickerPlugin *plugin = [FLTImagePickerPlugin new ];
10195 FlutterMethodCall *call =
10296 [FlutterMethodCall methodCallWithMethodName: @" pickImage"
10397 arguments: @{@" source" : @(0 ), @" cameraDevice" : @(0 )}];
0 commit comments