[flutter_tools] reduce doctor timeout to debug 111686 (#111687)

This commit is contained in:
Christopher Fujino 2022-09-15 13:59:17 -07:00 committed by GitHub
parent af8271b678
commit 6bb2018af7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -345,7 +345,9 @@ class Doctor {
/// Maximum allowed duration for an entire validator to take.
///
/// This should only ever be reached if a process is stuck.
static const Duration doctorDuration = Duration(minutes: 10);
// Reduce this to under 5 minutes to diagnose:
// https://github.com/flutter/flutter/issues/111686
static const Duration doctorDuration = Duration(minutes: 4, seconds: 30);
/// Print information about the state of installed tooling.
///

View File

@ -354,7 +354,7 @@ void main() {
FakeAsync().run<void>((FakeAsync time) {
final Doctor doctor = FakeAsyncStuckDoctor(logger);
doctor.diagnose(verbose: false);
time.elapse(Doctor.doctorDuration + const Duration(seconds: 1));
time.elapse(const Duration(minutes: 5));
time.flushMicrotasks();
});