Commit 10c861d6 authored by Ian Hickson's avatar Ian Hickson

Track number of pending dartdocs too (#4088)

parent 06d80f22
......@@ -230,7 +230,7 @@ class AnalyzeCommand extends FlutterCommand {
String elapsed = (stopwatch.elapsedMilliseconds / 1000.0).toStringAsFixed(1);
if (_isBenchmarking)
_writeBenchmark(stopwatch, errorCount);
_writeBenchmark(stopwatch, errorCount, membersMissingDocumentation);
if (errorCount > 0) {
if (membersMissingDocumentation > 0 && argResults['flutter-repo'])
......@@ -346,7 +346,7 @@ class AnalyzeCommand extends FlutterCommand {
printStatus('$errorsMessage • analyzed $files, $seconds seconds');
if (firstAnalysis && _isBenchmarking) {
_writeBenchmark(analysisTimer, issueCount);
_writeBenchmark(analysisTimer, issueCount, -1); // TODO(ianh): track members missing dartdocs instead of saying -1
server.dispose().then((_) => exit(0));
}
......@@ -370,11 +370,12 @@ class AnalyzeCommand extends FlutterCommand {
return false;
}
void _writeBenchmark(Stopwatch stopwatch, int errorCount) {
void _writeBenchmark(Stopwatch stopwatch, int errorCount, int membersMissingDocumentation) {
final String benchmarkOut = 'analysis_benchmark.json';
Map<String, dynamic> data = <String, dynamic>{
'time': (stopwatch.elapsedMilliseconds / 1000.0),
'issues': errorCount
'issues': errorCount,
'missingDartDocs': membersMissingDocumentation
};
new File(benchmarkOut).writeAsStringSync(toPrettyJson(data));
printStatus('Analysis benchmark written to $benchmarkOut ($data).');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment