Unverified Commit d7f80fcd authored by Jonah Williams's avatar Jonah Williams Committed by GitHub

[flutter_tools] configure screenshot on failure for all tasks (#68260)

parent acde65d1
...@@ -282,6 +282,7 @@ Future<Process> startProcess( ...@@ -282,6 +282,7 @@ Future<Process> startProcess(
+ (environment != null ? ' with environment $environment' : '')); + (environment != null ? ' with environment $environment' : ''));
environment ??= <String, String>{}; environment ??= <String, String>{};
environment['BOT'] = isBot ? 'true' : 'false'; environment['BOT'] = isBot ? 'true' : 'false';
environment['FLUTTER_IOS_SCREENSHOT_ON_CONNECTION_FAILURE'] = 'true';
final Process process = await _processManager.start( final Process process = await _processManager.start(
<String>[executable, ...arguments], <String>[executable, ...arguments],
environment: environment, environment: environment,
...@@ -447,7 +448,7 @@ Future<int> flutter(String command, { ...@@ -447,7 +448,7 @@ Future<int> flutter(String command, {
}) { }) {
final List<String> args = flutterCommandArgs(command, options); final List<String> args = flutterCommandArgs(command, options);
return exec(path.join(flutterDirectory.path, 'bin', 'flutter'), args, return exec(path.join(flutterDirectory.path, 'bin', 'flutter'), args,
canFail: canFail, environment: <String, String>{...?environment, 'FLUTTER_IOS_SCREENSHOT_ON_CONNECTION_FAILURE': 'true'}); canFail: canFail, environment: environment);
} }
/// Runs a `flutter` command and returns the standard output as a string. /// Runs a `flutter` command and returns the standard output as a string.
......
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