Flutterã§mockitoãå©ç¨ãããåä½ãã¹ãã§æ°æéããã£ãã®ã§ã¡ã¢ãã¦ããã¾ãã çºçããissue mockã¯ã©ã¹ãNullã許容ãã¦ãããããmockåããã¯ã©ã¹ã¨åã®æ´åæ§ããªããã¨ã©ã¼ã¨ãªãã Null Safety対å¿ï¼=Null許容ããªãï¼ããã«ã¯ãç¹å¥ãªå¯¾å¿ãå¿ è¦ã¨ãªãã 対象ã®ã³ã¼ã when(mock.auth(email: '[email protected]', password: 'password')) .thenAnswer((_) => Future.value(response)); type 'Null' is not a subtype of type 'Future<ApiResponse>' package:flutter_with_getx/data/repository/auth_repository.dart 9:23 MockAuthRep
I am trying to test a method that uses FirebaseFirestore but I am not able to mock the FirebaseFirestore.instance property. I am following these examples: Initializing the core: https://firebase.flutter.dev/docs/overview#initializing-flutterfire Using the firestore plugin: https://firebase.flutter.dev/docs/firestore/usage I am using the code below for my class and it is working well, which means t
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}