bringToFront method
Brings the running appId on simulator udid to the front; simctl reactivates the same process instead of starting another.
Implementation
Future<void> bringToFront(String udid, String appId) async {
final launch = await _run('xcrun', ['simctl', 'launch', udid, appId]);
if (launch.exitCode != 0) {
throw InstalledLaunchError(
InstalledLaunchFailure.toolFailed, 'simctl could not bring $appId to the front on $udid',
detail: _firstNonEmpty(launch.stderr, launch.stdout));
}
}