@@ -121,7 +121,7 @@ void main() {
121121
122122 test ('should call timers occurring at the same time in FIFO order' , () {
123123 FakeAsync ().run ((async ) {
124- final log = [];
124+ final log = < String > [];
125125 Timer (elapseBy ~ / 2 , () => log.add ('1' ));
126126 Timer (elapseBy ~ / 2 , () => log.add ('2' ));
127127 async .elapse (elapseBy);
@@ -131,7 +131,7 @@ void main() {
131131
132132 test ('should maintain FIFO order even with periodic timers' , () {
133133 FakeAsync ().run ((async ) {
134- final log = [];
134+ final log = < String > [];
135135 Timer .periodic (elapseBy ~ / 2 , (_) => log.add ('periodic 1' ));
136136 Timer (elapseBy ~ / 2 , () => log.add ('delayed 1' ));
137137 Timer (elapseBy, () => log.add ('delayed 2' ));
@@ -191,7 +191,7 @@ void main() {
191191
192192 test ('should add event before advancing time' , () {
193193 FakeAsync ().run ((async ) {
194- final controller = StreamController ();
194+ final controller = StreamController < void > ();
195195 expect (controller.stream.first.then ((_) {
196196 expect (async .elapsed, Duration .zero);
197197 }), completes);
@@ -259,7 +259,7 @@ void main() {
259259
260260 test ('should work with Future.timeout' , () {
261261 FakeAsync ().run ((async ) {
262- final completer = Completer ();
262+ final completer = Completer < void > ();
263263 expect (completer.future.timeout (elapseBy ~ / 2 ),
264264 throwsA (const TypeMatcher <TimeoutException >()));
265265 async .elapse (elapseBy);
@@ -285,7 +285,7 @@ void main() {
285285 final timed = controller.stream.timeout (const Duration (minutes: 2 ));
286286
287287 final events = < int > [];
288- final errors = [];
288+ final errors = < Object > [];
289289 timed.listen (events.add, onError: errors.add);
290290
291291 controller.add (0 );
@@ -310,7 +310,7 @@ void main() {
310310
311311 test ('should flush microtasks scheduled by microtasks in order' , () {
312312 FakeAsync ().run ((async ) {
313- final log = [];
313+ final log = < int > [];
314314 scheduleMicrotask (() {
315315 log.add (1 );
316316 scheduleMicrotask (() => log.add (3 ));
@@ -324,7 +324,7 @@ void main() {
324324
325325 test ('should not run timers' , () {
326326 FakeAsync ().run ((async ) {
327- final log = [];
327+ final log = < int > [];
328328 scheduleMicrotask (() => log.add (1 ));
329329 Timer .run (() => log.add (2 ));
330330 Timer .periodic (const Duration (seconds: 1 ), (_) => log.add (2 ));
@@ -338,7 +338,7 @@ void main() {
338338 group ('flushTimers' , () {
339339 test ('should flush timers in FIFO order' , () {
340340 FakeAsync ().run ((async ) {
341- final log = [];
341+ final log = < int > [];
342342 Timer .run (() {
343343 log.add (1 );
344344 Timer (elapseBy, () => log.add (3 ));
@@ -355,7 +355,7 @@ void main() {
355355 'should run collateral periodic timers with non-periodic first if '
356356 'scheduled first' , () {
357357 FakeAsync ().run ((async ) {
358- final log = [];
358+ final log = < String > [];
359359 Timer (const Duration (seconds: 2 ), () => log.add ('delayed' ));
360360 Timer .periodic (const Duration (seconds: 1 ), (_) => log.add ('periodic' ));
361361
@@ -368,7 +368,7 @@ void main() {
368368 'should run collateral periodic timers with periodic first '
369369 'if scheduled first' , () {
370370 FakeAsync ().run ((async ) {
371- final log = [];
371+ final log = < String > [];
372372 Timer .periodic (const Duration (seconds: 1 ), (_) => log.add ('periodic' ));
373373 Timer (const Duration (seconds: 2 ), () => log.add ('delayed' ));
374374
@@ -574,7 +574,7 @@ void main() {
574574
575575 test ('should increment tick in a periodic timer' , () {
576576 return FakeAsync ().run ((async ) {
577- final ticks = [];
577+ final ticks = < int > [];
578578 Timer .periodic (
579579 elapseBy,
580580 expectAsync1 ((timer) {
0 commit comments