| Flutter macOS Embedder |

FlutterViewControllerTestUtils.mm
Go to the documentation of this file.
1 // Copyright 2013 The Flutter Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #import "flutter/shell/platform/darwin/macos/framework/Source/FlutterViewControllerTestUtils.h"
6
7 namespace flutter::testing {
8
9 id CreateMockViewController() {
10 {
11 NSString* fixtures = @(testing::GetFixturesPath());
12 FlutterDartProject* project = [[FlutterDartProject alloc]
13 initWithAssetsPath:fixtures
14 ICUDataPath:[fixtures stringByAppendingString:@"/icudtl.dat"]];
15 FlutterViewController* viewController = [[FlutterViewController alloc] initWithProject:project];
16 id viewControllerMock = OCMPartialMock(viewController);
17 return viewControllerMock;
18 }
19 }
20
21 } // namespace flutter::testing
FlutterViewControllerTestUtils.h
FlutterDartProject
Definition: FlutterDartProject.mm:39
FlutterViewController
Definition: FlutterViewController.h:73
flutter::testing
Definition: AccessibilityBridgeMacTest.mm:13
flutter::testing::CreateMockViewController
id CreateMockViewController()
Definition: FlutterViewControllerTestUtils.mm:9