Fix some tests to be happy with proper microtask scheduling. (#12900)
(I suspect this accounts the sets of microtasks from scheduleWarmUpFrame now running separately.) Issue https://github.com/flutter/flutter/issues/9998
This commit is contained in:
@@ -75,6 +75,7 @@ Future<Map<String, String>> hasReassemble(Future<Map<String, String>> pendingRes
|
||||
await binding.flushMicrotasks();
|
||||
expect(binding.frameScheduled, isTrue);
|
||||
expect(completed, isFalse);
|
||||
await binding.flushMicrotasks();
|
||||
await binding.doFrame();
|
||||
await binding.flushMicrotasks();
|
||||
expect(completed, isTrue);
|
||||
@@ -411,6 +412,7 @@ void main() {
|
||||
await binding.flushMicrotasks();
|
||||
expect(binding.frameScheduled, isTrue);
|
||||
expect(completed, false);
|
||||
await binding.flushMicrotasks();
|
||||
await binding.doFrame();
|
||||
await binding.flushMicrotasks();
|
||||
expect(completed, true);
|
||||
|
||||
Reference in New Issue
Block a user