[ CLI ] Avoid awaiting on join() calls in test harness

Fixes #47750

Change-Id: I179a9e987cea157257d40d6e840e9f4ff5539877
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/221543
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: William Hesse <whesse@google.com>
This commit is contained in:
Ben Konyi 2021-11-30 16:39:25 +00:00 committed by Commit Bot
parent 1926ff8c67
commit c39b243435

View file

@ -113,15 +113,14 @@ dev_dependencies:
],
workingDirectory: workingDir ?? dir.path,
environment: {if (logAnalytics) '_DARTDEV_LOG_ANALYTICS': 'true'});
final stdoutContents = await _process.stdout.transform(utf8.decoder).join();
final stderrContents = await _process.stderr.transform(utf8.decoder).join();
final stdoutContents = _process.stdout.transform(utf8.decoder).join();
final stderrContents = _process.stderr.transform(utf8.decoder).join();
final code = await _process.exitCode;
return ProcessResult(
_process.pid,
code,
stdoutContents,
stderrContents,
await stdoutContents,
await stderrContents,
);
}