Respect --enable-software-rendering flag on iOS simulators (#67576)
This commit is contained in:
@@ -423,6 +423,7 @@ class IOSSimulator extends Device {
|
||||
'--enable-checked-mode',
|
||||
'--verify-entry-points',
|
||||
],
|
||||
if (debuggingOptions.enableSoftwareRendering) '--enable-software-rendering',
|
||||
if (debuggingOptions.startPaused) '--start-paused',
|
||||
if (debuggingOptions.disableServiceAuthCodes) '--disable-service-auth-codes',
|
||||
if (debuggingOptions.skiaDeterministicRendering) '--skia-deterministic-rendering',
|
||||
|
||||
@@ -910,6 +910,29 @@ Dec 20 17:04:32 md32-11-vm1 Another App[88374]: Ignore this text'''
|
||||
FileSystem: () => fileSystem,
|
||||
ProcessManager: () => FakeProcessManager.any(),
|
||||
});
|
||||
|
||||
testUsingContext('startApp respects the enable software rendering flag', () async {
|
||||
final IOSSimulator device = IOSSimulator(
|
||||
'x',
|
||||
name: 'iPhone SE',
|
||||
simulatorCategory: 'iOS 11.2',
|
||||
simControl: simControl,
|
||||
xcode: mockXcode,
|
||||
);
|
||||
|
||||
final Directory mockDir = globals.fs.currentDirectory;
|
||||
final IOSApp package = PrebuiltIOSApp(projectBundleId: 'incorrect', bundleName: 'name', bundleDir: mockDir);
|
||||
|
||||
const BuildInfo mockInfo = BuildInfo(BuildMode.debug, 'flavor', treeShakeIcons: false);
|
||||
final DebuggingOptions mockOptions = DebuggingOptions.enabled(mockInfo, enableSoftwareRendering: true);
|
||||
await device.startApp(package, prebuiltApplication: true, debuggingOptions: mockOptions);
|
||||
|
||||
verify(simControl.launch(any, any, captureAny)).captured.contains('--enable-software-rendering');
|
||||
}, overrides: <Type, Generator>{
|
||||
PlistParser: () => MockPlistUtils(),
|
||||
FileSystem: () => fileSystem,
|
||||
ProcessManager: () => FakeProcessManager.any(),
|
||||
});
|
||||
});
|
||||
|
||||
group('IOSDevice.isSupportedForProject', () {
|
||||
|
||||
Reference in New Issue
Block a user