| Index: utils/testrunner/utils.dart
|
| diff --git a/utils/testrunner/utils.dart b/utils/testrunner/utils.dart
|
| index e8f81d4a9461aef0c339740ee2117cc20eee3ef3..3bd7efb169b095307d89646a428f397700369566 100644
|
| --- a/utils/testrunner/utils.dart
|
| +++ b/utils/testrunner/utils.dart
|
| @@ -70,21 +70,24 @@ void buildFileList(List dirs, RegExp filePat, bool recurse,
|
| Directory d = new Directory(path);
|
| if (d.existsSync()) {
|
| ++dirCount;
|
| - var lister = d.list(recursive: recurse);
|
| - lister.onFile = (file) {
|
| - if (filePat.hasMatch(file)) {
|
| - if (excludePat == null || !excludePat.hasMatch(file)) {
|
| - if (includeSymLinks || file.startsWith(path)) {
|
| - files.add(file);
|
| + d.list(recursive: recurse).listen(
|
| + (entity) {
|
| + if (entity is File) {
|
| + var file = entity.name;
|
| + if (filePat.hasMatch(file)) {
|
| + if (excludePat == null || !excludePat.hasMatch(file)) {
|
| + if (includeSymLinks || file.startsWith(path)) {
|
| + files.add(file);
|
| + }
|
| + }
|
| + }
|
| }
|
| - }
|
| - }
|
| - };
|
| - lister.onDone = (complete) {
|
| - if (complete && --dirCount == 0) {
|
| - onComplete(files);
|
| - }
|
| - };
|
| + },
|
| + onDone: () {
|
| + if (complete && --dirCount == 0) {
|
| + onComplete(files);
|
| + }
|
| + });
|
| } else { // Does not exist.
|
| print('$path does not exist.');
|
| }
|
|
|