Unverified Commit e8bd5a32 authored by Victoria Ashworth's avatar Victoria Ashworth Committed by GitHub

Delete simulator after plugin_test_ios (#136265)

Remove simulator once it's no longer needed for test `plugin_test_ios` .

Fixes https://github.com/flutter/flutter/issues/136224
parent 5064f782
......@@ -263,7 +263,10 @@ public class $pluginClass: NSObject, FlutterPlugin {
throw TaskResult.failure('Platform unit tests failed');
}
case 'ios':
String? simulatorDeviceId;
try {
await testWithNewIOSSimulator('TestNativeUnitTests', (String deviceId) async {
simulatorDeviceId = deviceId;
if (!await runXcodeTests(
platformDirectory: path.join(rootPath, 'ios'),
destination: 'id=$deviceId',
......@@ -274,6 +277,9 @@ public class $pluginClass: NSObject, FlutterPlugin {
throw TaskResult.failure('Platform unit tests failed');
}
});
} finally {
await removeIOSimulator(simulatorDeviceId);
}
case 'linux':
if (await exec(
path.join(rootPath, 'build', 'linux', 'x64', 'release', 'plugins', 'plugintest', 'plugintest_test'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment