@@ -246,7 +246,7 @@ void main() {
246246 });
247247 test ('listen' , () async {
248248 final QuerySnapshot snapshot =
249- await collectionReference.snapshots.first;
249+ await collectionReference.snapshots () .first;
250250 final DocumentSnapshot document = snapshot.documents[0 ];
251251 expect (document.documentID, equals ('0' ));
252252 expect (document.reference.path, equals ('foo/0' ));
@@ -275,7 +275,7 @@ void main() {
275275 final StreamSubscription <QuerySnapshot > subscription =
276276 collectionReference
277277 .where ('createdAt' , isLessThan: 100 )
278- .snapshots
278+ .snapshots ()
279279 .listen ((QuerySnapshot querySnapshot) {});
280280 subscription.cancel ();
281281 await new Future <Null >.delayed (Duration .zero);
@@ -306,7 +306,7 @@ void main() {
306306 final StreamSubscription <QuerySnapshot > subscription =
307307 collectionReference
308308 .where ('profile' , isNull: true )
309- .snapshots
309+ .snapshots ()
310310 .listen ((QuerySnapshot querySnapshot) {});
311311 subscription.cancel ();
312312 await new Future <Null >.delayed (Duration .zero);
@@ -337,7 +337,7 @@ void main() {
337337 final StreamSubscription <QuerySnapshot > subscription =
338338 collectionReference
339339 .orderBy ('createdAt' )
340- .snapshots
340+ .snapshots ()
341341 .listen ((QuerySnapshot querySnapshot) {});
342342 subscription.cancel ();
343343 await new Future <Null >.delayed (Duration .zero);
@@ -369,7 +369,7 @@ void main() {
369369 group ('DocumentReference' , () {
370370 test ('listen' , () async {
371371 final DocumentSnapshot snapshot =
372- await firestore.document ('path/to/foo' ).snapshots.first;
372+ await firestore.document ('path/to/foo' ).snapshots () .first;
373373 expect (snapshot.documentID, equals ('foo' ));
374374 expect (snapshot.reference.path, equals ('path/to/foo' ));
375375 expect (snapshot.data, equals (kMockDocumentSnapshotData));
@@ -405,7 +405,7 @@ void main() {
405405 'app' : app.name,
406406 'path' : 'foo/bar' ,
407407 'data' : < String , String > {'bazKey' : 'quxValue' },
408- 'options' : null ,
408+ 'options' : < String , bool > { 'merge' : false } ,
409409 },
410410 ),
411411 ],
@@ -414,8 +414,7 @@ void main() {
414414 test ('merge set' , () async {
415415 await collectionReference
416416 .document ('bar' )
417- .setData (< String , String > {'bazKey' : 'quxValue' }, SetOptions .merge);
418- expect (SetOptions .merge, isNotNull);
417+ .setData (< String , String > {'bazKey' : 'quxValue' }, merge: true );
419418 expect (
420419 log,
421420 < Matcher > [
@@ -576,7 +575,7 @@ void main() {
576575 'handle' : 1 ,
577576 'path' : 'foo/bar' ,
578577 'data' : < String , String > {'bazKey' : 'quxValue' },
579- 'options' : null ,
578+ 'options' : < String , bool > { 'merge' : false } ,
580579 },
581580 ),
582581 isMethodCall (
@@ -593,10 +592,9 @@ void main() {
593592 batch.setData (
594593 collectionReference.document ('bar' ),
595594 < String , String > {'bazKey' : 'quxValue' },
596- SetOptions . merge,
595+ merge: true ,
597596 );
598597 await batch.commit ();
599- expect (SetOptions .merge, isNotNull);
600598 expect (
601599 log,
602600 < Matcher > [
0 commit comments