Skip to content

Commit bcac1bd

Browse files
authored
Handle the case where there are no missing dartdocs too... (flutter#24801)
1 parent 9ca129d commit bcac1bd

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

dev/devicelab/bin/tasks/dartdocs.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ Future<void> main() async {
2121
int publicMembers = 0;
2222
int otherErrors = 0;
2323
int otherLines = 0;
24+
bool sawFinalLine = false;
2425
await for (String entry in analysis.stdout.transform<String>(utf8.decoder).transform<String>(const LineSplitter())) {
2526
entry = entry.trim();
2627
print('analyzer stdout: $entry');
@@ -30,17 +31,17 @@ Future<void> main() async {
3031
publicMembers += 1;
3132
} else if (entry.startsWith('info •') || entry.startsWith('warning •') || entry.startsWith('error •')) {
3233
otherErrors += 1;
33-
} else if (entry.contains(' (ran in ')) {
34-
// ignore this line
34+
} else if (entry.contains(' (ran in ') && !sawFinalLine) {
35+
// ignore this line once
36+
sawFinalLine = true;
3537
} else if (entry.isNotEmpty) {
3638
otherLines += 1;
3739
print('^ not sure what to do with that line ^');
3840
}
3941
}
40-
bool sawFinalLine = false;
4142
await for (String entry in analysis.stderr.transform<String>(utf8.decoder).transform<String>(const LineSplitter())) {
4243
print('analyzer stderr: $entry');
43-
if (entry.contains('(ran in ') && !sawFinalLine) {
44+
if (entry.contains(' (ran in ') && !sawFinalLine) {
4445
// ignore this line once
4546
sawFinalLine = true;
4647
} else {

0 commit comments

Comments
 (0)