mirror of
https://github.com/flutter/flutter
synced 2024-10-13 11:42:54 +00:00
More dart 2 fixes to fuchsia_tester.dart (#19846)
This commit is contained in:
parent
730a534fbb
commit
7ea164ecb5
|
@ -38,12 +38,13 @@ void main(List<String> args) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Iterable<String> _findTests(Directory directory) {
|
List<String> _findTests(Directory directory) {
|
||||||
return directory
|
return directory
|
||||||
.listSync(recursive: true, followLinks: false)
|
.listSync(recursive: true, followLinks: false)
|
||||||
.where((FileSystemEntity entity) =>
|
.where((FileSystemEntity entity) =>
|
||||||
entity.path.endsWith('_test.dart') && fs.isFileSync(entity.path))
|
entity.path.endsWith('_test.dart') && fs.isFileSync(entity.path))
|
||||||
.map((FileSystemEntity entity) => fs.path.absolute(entity.path));
|
.map((FileSystemEntity entity) => fs.path.absolute(entity.path))
|
||||||
|
.toList();
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<Null> run(List<String> args) async {
|
Future<Null> run(List<String> args) async {
|
||||||
|
@ -71,7 +72,7 @@ Future<Null> run(List<String> args) async {
|
||||||
Cache.flutterRoot = tempDirectory.path;
|
Cache.flutterRoot = tempDirectory.path;
|
||||||
final Directory testDirectory =
|
final Directory testDirectory =
|
||||||
fs.directory(argResults[_kOptionTestDirectory]);
|
fs.directory(argResults[_kOptionTestDirectory]);
|
||||||
final Iterable<String> tests = _findTests(testDirectory);
|
final List<String> tests = _findTests(testDirectory);
|
||||||
|
|
||||||
final List<String> testArgs = <String>[];
|
final List<String> testArgs = <String>[];
|
||||||
testArgs.add('--');
|
testArgs.add('--');
|
||||||
|
|
Loading…
Reference in a new issue