mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
Use (processors-1) for test runs (test defaults to processors/2) (#22803)
* Use (processors-1) for test runs (test defaults to processors/2)
* Add missing import 🙄
This commit is contained in:
parent
be0dde4114
commit
b357b55904
@ -4,6 +4,7 @@
|
||||
|
||||
import 'dart:async';
|
||||
import 'dart:io';
|
||||
import 'dart:math' as math;
|
||||
|
||||
import 'package:path/path.dart' as path;
|
||||
|
||||
@ -223,6 +224,8 @@ Future<void> _pubRunTest(
|
||||
bool enableFlutterToolAsserts = false
|
||||
}) {
|
||||
final List<String> args = <String>['run', 'test', '-rcompact'];
|
||||
final int concurrency = math.max(1, Platform.numberOfProcessors - 1);
|
||||
args.add('-j$concurrency');
|
||||
if (!hasColor)
|
||||
args.add('--no-color');
|
||||
if (testPath != null)
|
||||
|
Loading…
Reference in New Issue
Block a user