Flutter Engine
PlatformViewUITests.m
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 
6 
8 
9 @end
10 
11 @implementation PlatformViewUITests
12 
13 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
15  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view"];
16  return [super initWithManager:manager invocation:invocation];
17 }
18 
19 - (void)testPlatformView {
20  [self checkGolden];
21 }
22 
23 @end
24 
26 
27 @end
28 
29 @implementation MultiplePlatformViewsTest
30 
31 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
33  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-multiple"];
34  return [super initWithManager:manager invocation:invocation];
35 }
36 
37 - (void)testPlatformView {
38  [self checkGolden];
39 }
40 
41 @end
42 
44 
45 @end
46 
48 
49 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
51  initWithLaunchArg:@"--platform-view-multiple-background-foreground"];
52  return [super initWithManager:manager invocation:invocation];
53 }
54 
55 - (void)testPlatformView {
56  [[XCUIDevice sharedDevice] pressButton:XCUIDeviceButtonHome];
57  [self.application activate];
58  [self checkGolden];
59 }
60 
61 @end
62 
63 // Clip Rect Tests
65 
66 @end
67 
69 
70 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
72  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-cliprect"];
73  return [super initWithManager:manager invocation:invocation];
74 }
75 
76 - (void)testPlatformView {
77  [self checkGolden];
78 }
79 
80 @end
81 
83 
84 @end
85 
87 
88 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
90  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-cliprrect"];
91  return [super initWithManager:manager invocation:invocation];
92 }
93 
94 - (void)testPlatformView {
95  [self checkGolden];
96 }
97 
98 @end
99 
101 
102 @end
103 
104 @implementation PlatformViewMutationClipPathTests
105 
106 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
108  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-clippath"];
109  return [super initWithManager:manager invocation:invocation];
110 }
111 
112 - (void)testPlatformView {
113  [self checkGolden];
114 }
115 
116 @end
117 
119 
120 @end
121 
123 
124 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
126  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-transform"];
127  return [super initWithManager:manager invocation:invocation];
128 }
129 
130 - (void)testPlatformView {
131  [self checkGolden];
132 }
133 
134 @end
135 
137 
138 @end
139 
140 @implementation PlatformViewMutationOpacityTests
141 
142 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
144  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-opacity"];
145  return [super initWithManager:manager invocation:invocation];
146 }
147 
148 - (void)testPlatformView {
149  [self checkGolden];
150 }
151 
152 @end
153 
155 @end
156 
157 @implementation PlatformViewRotation
158 - (instancetype)initWithInvocation:(NSInvocation*)invocation {
160  [[PlatformViewGoldenTestManager alloc] initWithLaunchArg:@"--platform-view-rotate"];
161  return [super initWithManager:manager invocation:invocation];
162 }
163 
164 - (void)tearDown {
165  XCUIDevice.sharedDevice.orientation = UIDeviceOrientationPortrait;
166  [super tearDown];
167 }
168 
169 - (void)testPlatformView {
170  XCUIDevice.sharedDevice.orientation = UIDeviceOrientationLandscapeLeft;
171  [self checkGolden];
172 }
173 @end
instancetype initWithManager:invocation:(PlatformViewGoldenTestManager *manager, [invocation] NSInvocation *invocation)