1// Mocks generated by Mockito 5.4.6 from annotations 2// in coves_flutter/test/providers/comments_provider_test.dart. 3// Do not manually edit this file. 4 5// ignore_for_file: no_leading_underscores_for_library_prefixes 6import 'dart:async' as _i6; 7import 'dart:ui' as _i7; 8 9import 'package:coves_flutter/models/comment.dart' as _i3; 10import 'package:coves_flutter/models/post.dart' as _i2; 11import 'package:coves_flutter/providers/auth_provider.dart' as _i5; 12import 'package:coves_flutter/providers/vote_provider.dart' as _i9; 13import 'package:coves_flutter/services/coves_api_service.dart' as _i8; 14import 'package:coves_flutter/services/vote_service.dart' as _i4; 15import 'package:mockito/mockito.dart' as _i1; 16 17// ignore_for_file: type=lint 18// ignore_for_file: avoid_redundant_argument_values 19// ignore_for_file: avoid_setters_without_getters 20// ignore_for_file: comment_references 21// ignore_for_file: deprecated_member_use 22// ignore_for_file: deprecated_member_use_from_same_package 23// ignore_for_file: implementation_imports 24// ignore_for_file: invalid_use_of_visible_for_testing_member 25// ignore_for_file: must_be_immutable 26// ignore_for_file: prefer_const_constructors 27// ignore_for_file: unnecessary_parenthesis 28// ignore_for_file: camel_case_types 29// ignore_for_file: subtype_of_sealed_class 30// ignore_for_file: invalid_use_of_internal_member 31 32class _FakeTimelineResponse_0 extends _i1.SmartFake 33 implements _i2.TimelineResponse { 34 _FakeTimelineResponse_0(Object parent, Invocation parentInvocation) 35 : super(parent, parentInvocation); 36} 37 38class _FakeCommentsResponse_1 extends _i1.SmartFake 39 implements _i3.CommentsResponse { 40 _FakeCommentsResponse_1(Object parent, Invocation parentInvocation) 41 : super(parent, parentInvocation); 42} 43 44class _FakeVoteResponse_2 extends _i1.SmartFake implements _i4.VoteResponse { 45 _FakeVoteResponse_2(Object parent, Invocation parentInvocation) 46 : super(parent, parentInvocation); 47} 48 49/// A class which mocks [AuthProvider]. 50/// 51/// See the documentation for Mockito's code generation for more information. 52class MockAuthProvider extends _i1.Mock implements _i5.AuthProvider { 53 MockAuthProvider() { 54 _i1.throwOnMissingStub(this); 55 } 56 57 @override 58 bool get isAuthenticated => 59 (super.noSuchMethod( 60 Invocation.getter(#isAuthenticated), 61 returnValue: false, 62 ) 63 as bool); 64 65 @override 66 bool get isLoading => 67 (super.noSuchMethod(Invocation.getter(#isLoading), returnValue: false) 68 as bool); 69 70 @override 71 bool get hasListeners => 72 (super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) 73 as bool); 74 75 @override 76 _i6.Future<String?> getAccessToken() => 77 (super.noSuchMethod( 78 Invocation.method(#getAccessToken, []), 79 returnValue: _i6.Future<String?>.value(), 80 ) 81 as _i6.Future<String?>); 82 83 @override 84 _i6.Future<void> initialize() => 85 (super.noSuchMethod( 86 Invocation.method(#initialize, []), 87 returnValue: _i6.Future<void>.value(), 88 returnValueForMissingStub: _i6.Future<void>.value(), 89 ) 90 as _i6.Future<void>); 91 92 @override 93 _i6.Future<void> signIn(String? handle) => 94 (super.noSuchMethod( 95 Invocation.method(#signIn, [handle]), 96 returnValue: _i6.Future<void>.value(), 97 returnValueForMissingStub: _i6.Future<void>.value(), 98 ) 99 as _i6.Future<void>); 100 101 @override 102 _i6.Future<void> signOut() => 103 (super.noSuchMethod( 104 Invocation.method(#signOut, []), 105 returnValue: _i6.Future<void>.value(), 106 returnValueForMissingStub: _i6.Future<void>.value(), 107 ) 108 as _i6.Future<void>); 109 110 @override 111 void clearError() => super.noSuchMethod( 112 Invocation.method(#clearError, []), 113 returnValueForMissingStub: null, 114 ); 115 116 @override 117 void dispose() => super.noSuchMethod( 118 Invocation.method(#dispose, []), 119 returnValueForMissingStub: null, 120 ); 121 122 @override 123 void addListener(_i7.VoidCallback? listener) => super.noSuchMethod( 124 Invocation.method(#addListener, [listener]), 125 returnValueForMissingStub: null, 126 ); 127 128 @override 129 void removeListener(_i7.VoidCallback? listener) => super.noSuchMethod( 130 Invocation.method(#removeListener, [listener]), 131 returnValueForMissingStub: null, 132 ); 133 134 @override 135 void notifyListeners() => super.noSuchMethod( 136 Invocation.method(#notifyListeners, []), 137 returnValueForMissingStub: null, 138 ); 139} 140 141/// A class which mocks [CovesApiService]. 142/// 143/// See the documentation for Mockito's code generation for more information. 144class MockCovesApiService extends _i1.Mock implements _i8.CovesApiService { 145 MockCovesApiService() { 146 _i1.throwOnMissingStub(this); 147 } 148 149 @override 150 _i6.Future<_i2.TimelineResponse> getTimeline({ 151 String? sort = 'hot', 152 String? timeframe, 153 int? limit = 15, 154 String? cursor, 155 }) => 156 (super.noSuchMethod( 157 Invocation.method(#getTimeline, [], { 158 #sort: sort, 159 #timeframe: timeframe, 160 #limit: limit, 161 #cursor: cursor, 162 }), 163 returnValue: _i6.Future<_i2.TimelineResponse>.value( 164 _FakeTimelineResponse_0( 165 this, 166 Invocation.method(#getTimeline, [], { 167 #sort: sort, 168 #timeframe: timeframe, 169 #limit: limit, 170 #cursor: cursor, 171 }), 172 ), 173 ), 174 ) 175 as _i6.Future<_i2.TimelineResponse>); 176 177 @override 178 _i6.Future<_i2.TimelineResponse> getDiscover({ 179 String? sort = 'hot', 180 String? timeframe, 181 int? limit = 15, 182 String? cursor, 183 }) => 184 (super.noSuchMethod( 185 Invocation.method(#getDiscover, [], { 186 #sort: sort, 187 #timeframe: timeframe, 188 #limit: limit, 189 #cursor: cursor, 190 }), 191 returnValue: _i6.Future<_i2.TimelineResponse>.value( 192 _FakeTimelineResponse_0( 193 this, 194 Invocation.method(#getDiscover, [], { 195 #sort: sort, 196 #timeframe: timeframe, 197 #limit: limit, 198 #cursor: cursor, 199 }), 200 ), 201 ), 202 ) 203 as _i6.Future<_i2.TimelineResponse>); 204 205 @override 206 _i6.Future<_i3.CommentsResponse> getComments({ 207 required String? postUri, 208 String? sort = 'hot', 209 String? timeframe, 210 int? depth = 10, 211 int? limit = 50, 212 String? cursor, 213 }) => 214 (super.noSuchMethod( 215 Invocation.method(#getComments, [], { 216 #postUri: postUri, 217 #sort: sort, 218 #timeframe: timeframe, 219 #depth: depth, 220 #limit: limit, 221 #cursor: cursor, 222 }), 223 returnValue: _i6.Future<_i3.CommentsResponse>.value( 224 _FakeCommentsResponse_1( 225 this, 226 Invocation.method(#getComments, [], { 227 #postUri: postUri, 228 #sort: sort, 229 #timeframe: timeframe, 230 #depth: depth, 231 #limit: limit, 232 #cursor: cursor, 233 }), 234 ), 235 ), 236 ) 237 as _i6.Future<_i3.CommentsResponse>); 238 239 @override 240 void dispose() => super.noSuchMethod( 241 Invocation.method(#dispose, []), 242 returnValueForMissingStub: null, 243 ); 244} 245 246/// A class which mocks [VoteProvider]. 247/// 248/// See the documentation for Mockito's code generation for more information. 249class MockVoteProvider extends _i1.Mock implements _i9.VoteProvider { 250 MockVoteProvider() { 251 _i1.throwOnMissingStub(this); 252 } 253 254 @override 255 bool get hasListeners => 256 (super.noSuchMethod(Invocation.getter(#hasListeners), returnValue: false) 257 as bool); 258 259 @override 260 void dispose() => super.noSuchMethod( 261 Invocation.method(#dispose, []), 262 returnValueForMissingStub: null, 263 ); 264 265 @override 266 _i9.VoteState? getVoteState(String? postUri) => 267 (super.noSuchMethod(Invocation.method(#getVoteState, [postUri])) 268 as _i9.VoteState?); 269 270 @override 271 bool isLiked(String? postUri) => 272 (super.noSuchMethod( 273 Invocation.method(#isLiked, [postUri]), 274 returnValue: false, 275 ) 276 as bool); 277 278 @override 279 bool isPending(String? postUri) => 280 (super.noSuchMethod( 281 Invocation.method(#isPending, [postUri]), 282 returnValue: false, 283 ) 284 as bool); 285 286 @override 287 int getAdjustedScore(String? postUri, int? serverScore) => 288 (super.noSuchMethod( 289 Invocation.method(#getAdjustedScore, [postUri, serverScore]), 290 returnValue: 0, 291 ) 292 as int); 293 294 @override 295 _i6.Future<bool> toggleVote({ 296 required String? postUri, 297 required String? postCid, 298 String? direction = 'up', 299 }) => 300 (super.noSuchMethod( 301 Invocation.method(#toggleVote, [], { 302 #postUri: postUri, 303 #postCid: postCid, 304 #direction: direction, 305 }), 306 returnValue: _i6.Future<bool>.value(false), 307 ) 308 as _i6.Future<bool>); 309 310 @override 311 void setInitialVoteState({ 312 required String? postUri, 313 String? voteDirection, 314 String? voteUri, 315 }) => super.noSuchMethod( 316 Invocation.method(#setInitialVoteState, [], { 317 #postUri: postUri, 318 #voteDirection: voteDirection, 319 #voteUri: voteUri, 320 }), 321 returnValueForMissingStub: null, 322 ); 323 324 @override 325 void loadInitialVotes(Map<String, _i4.VoteInfo>? votes) => super.noSuchMethod( 326 Invocation.method(#loadInitialVotes, [votes]), 327 returnValueForMissingStub: null, 328 ); 329 330 @override 331 void clear() => super.noSuchMethod( 332 Invocation.method(#clear, []), 333 returnValueForMissingStub: null, 334 ); 335 336 @override 337 void addListener(_i7.VoidCallback? listener) => super.noSuchMethod( 338 Invocation.method(#addListener, [listener]), 339 returnValueForMissingStub: null, 340 ); 341 342 @override 343 void removeListener(_i7.VoidCallback? listener) => super.noSuchMethod( 344 Invocation.method(#removeListener, [listener]), 345 returnValueForMissingStub: null, 346 ); 347 348 @override 349 void notifyListeners() => super.noSuchMethod( 350 Invocation.method(#notifyListeners, []), 351 returnValueForMissingStub: null, 352 ); 353} 354 355/// A class which mocks [VoteService]. 356/// 357/// See the documentation for Mockito's code generation for more information. 358class MockVoteService extends _i1.Mock implements _i4.VoteService { 359 MockVoteService() { 360 _i1.throwOnMissingStub(this); 361 } 362 363 @override 364 _i6.Future<Map<String, _i4.VoteInfo>> getUserVotes() => 365 (super.noSuchMethod( 366 Invocation.method(#getUserVotes, []), 367 returnValue: _i6.Future<Map<String, _i4.VoteInfo>>.value( 368 <String, _i4.VoteInfo>{}, 369 ), 370 ) 371 as _i6.Future<Map<String, _i4.VoteInfo>>); 372 373 @override 374 _i6.Future<_i4.VoteResponse> createVote({ 375 required String? postUri, 376 required String? postCid, 377 String? direction = 'up', 378 String? existingVoteRkey, 379 String? existingVoteDirection, 380 }) => 381 (super.noSuchMethod( 382 Invocation.method(#createVote, [], { 383 #postUri: postUri, 384 #postCid: postCid, 385 #direction: direction, 386 #existingVoteRkey: existingVoteRkey, 387 #existingVoteDirection: existingVoteDirection, 388 }), 389 returnValue: _i6.Future<_i4.VoteResponse>.value( 390 _FakeVoteResponse_2( 391 this, 392 Invocation.method(#createVote, [], { 393 #postUri: postUri, 394 #postCid: postCid, 395 #direction: direction, 396 #existingVoteRkey: existingVoteRkey, 397 #existingVoteDirection: existingVoteDirection, 398 }), 399 ), 400 ), 401 ) 402 as _i6.Future<_i4.VoteResponse>); 403}