Respect CHROME_EXECUTABLE in web benchmarks (#49911)

This commit is contained in:
Yegor
2020-01-31 18:31:08 -08:00
committed by GitHub
parent 306c23fd36
commit ff7eb778f6

View File

@@ -149,6 +149,14 @@ Future<TaskResult> runWebBenchmark({ @required bool useCanvasKit }) async {
}
String _findSystemChromeExecutable() {
// On some environments, such as the Dart HHH tester, Chrome resides in a
// non-standard location and is provided via the following environment
// variable.
final String envExecutable = io.Platform.environment['CHROME_EXECUTABLE'];
if (envExecutable != null) {
return envExecutable;
}
if (io.Platform.isLinux) {
final io.ProcessResult which =
io.Process.runSync('which', <String>['google-chrome']);