Last active
November 18, 2020 19:03
-
-
Save utkarsh-UK/a8ab91c599cbf09c44148559ff982a84 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:cloud_firestore/cloud_firestore.dart'; | |
class MockFirestore extends Mock implements FirebaseFirestore {} | |
class MockCollectionReference extends Mock implements CollectionReference {} | |
class MockDocumentReference extends Mock implements DocumentReference {} | |
class MockDocumentSnapshot extends Mock implements DocumentSnapshot {} | |
void main() { | |
MockFirestore instance; | |
MockDocumentSnapshot mockDocumentSnapshot; | |
MockCollectionReference mockCollectionReference; | |
MockDocumentReference mockDocumentReference; | |
setUp(() { | |
instance = MockFirestore(); | |
mockCollectionReference = MockCollectionReference(); | |
mockDocumentReference = MockDocumentReference(); | |
mockDocumentSnapshot = MockDocumentSnapshot(); | |
}); | |
test('should return data when the call to remote source is successful.', () async { | |
// arrange | |
//act | |
//assert | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment