From 058e2a9fe9b32fc7d6913f270af2dfd7c9faae7f Mon Sep 17 00:00:00 2001 From: sorairo Date: Mon, 9 Oct 2023 13:40:26 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=86=E3=82=B9=E3=83=88=E3=82=B3=E3=83=BC?= =?UTF-8?q?=E3=83=89=E3=81=AE=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ios/Podfile.lock | 33 + lib/router/app_router.gr.dart | 1418 +++--- test/test_util/mock.dart | 19 +- test/test_util/mock.mocks.dart | 4223 +++++++++++------ test/test_util/test_datas.dart | 278 +- .../antenna_list_page_test.dart | 29 + .../antenna_notes_page_test.dart | 33 + .../channel_detail_page_test.dart | 172 + test/view/channel_page/channel_page_test.dart | 113 + .../clip_detail_page_test.dart | 30 + .../clip_list_page/clip_list_page_test.dart | 29 + test/view/explore_page/explore_page_test.dart | 230 + .../note_create_page_test.dart | 21 +- test/view/search_page/search_page_test.dart | 26 +- 14 files changed, 4488 insertions(+), 2166 deletions(-) create mode 100644 test/view/antenna_list_page/antenna_list_page_test.dart create mode 100644 test/view/antenna_notes_page/antenna_notes_page_test.dart create mode 100644 test/view/channel_detail_page/channel_detail_page_test.dart create mode 100644 test/view/channel_page/channel_page_test.dart create mode 100644 test/view/clip_detail_page/clip_detail_page_test.dart create mode 100644 test/view/clip_list_page/clip_list_page_test.dart create mode 100644 test/view/explore_page/explore_page_test.dart diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 2976cc0df..0e72126e1 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -36,6 +36,11 @@ PODS: - DKImagePickerController/PhotoGallery - Flutter - Flutter (1.0.0) + - flutter_image_compress_common (1.0.0): + - Flutter + - Mantle + - SDWebImage + - SDWebImageWebPCoder - flutter_secure_storage (6.0.0): - Flutter - FMDB (2.7.5): @@ -45,6 +50,21 @@ PODS: - Flutter - image_gallery_saver (2.0.2): - Flutter + - libwebp (1.3.2): + - libwebp/demux (= 1.3.2) + - libwebp/mux (= 1.3.2) + - libwebp/sharpyuv (= 1.3.2) + - libwebp/webp (= 1.3.2) + - libwebp/demux (1.3.2): + - libwebp/webp + - libwebp/mux (1.3.2): + - libwebp/demux + - libwebp/sharpyuv (1.3.2) + - libwebp/webp (1.3.2): + - libwebp/sharpyuv + - Mantle (2.2.0): + - Mantle/extobjc (= 2.2.0) + - Mantle/extobjc (2.2.0) - package_info_plus (0.4.5): - Flutter - path_provider_foundation (0.0.1): @@ -57,6 +77,9 @@ PODS: - SDWebImage (5.15.8): - SDWebImage/Core (= 5.15.8) - SDWebImage/Core (5.15.8) + - SDWebImageWebPCoder (0.11.0): + - libwebp (~> 1.0) + - SDWebImage/Core (~> 5.15) - share_plus (0.0.1): - Flutter - shared_preferences_foundation (0.0.1): @@ -73,6 +96,7 @@ DEPENDENCIES: - device_info_plus (from `.symlinks/plugins/device_info_plus/ios`) - file_picker (from `.symlinks/plugins/file_picker/ios`) - Flutter (from `Flutter`) + - flutter_image_compress_common (from `.symlinks/plugins/flutter_image_compress_common/ios`) - flutter_secure_storage (from `.symlinks/plugins/flutter_secure_storage/ios`) - image_editor_common (from `.symlinks/plugins/image_editor_common/ios`) - image_gallery_saver (from `.symlinks/plugins/image_gallery_saver/ios`) @@ -90,7 +114,10 @@ SPEC REPOS: - DKImagePickerController - DKPhotoGallery - FMDB + - libwebp + - Mantle - SDWebImage + - SDWebImageWebPCoder - SwiftyGif EXTERNAL SOURCES: @@ -100,6 +127,8 @@ EXTERNAL SOURCES: :path: ".symlinks/plugins/file_picker/ios" Flutter: :path: Flutter + flutter_image_compress_common: + :path: ".symlinks/plugins/flutter_image_compress_common/ios" flutter_secure_storage: :path: ".symlinks/plugins/flutter_secure_storage/ios" image_editor_common: @@ -129,15 +158,19 @@ SPEC CHECKSUMS: DKPhotoGallery: fdfad5125a9fdda9cc57df834d49df790dbb4179 file_picker: ce3938a0df3cc1ef404671531facef740d03f920 Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 + flutter_image_compress_common: ec1d45c362c9d30a3f6a0426c297f47c52007e3e flutter_secure_storage: 23fc622d89d073675f2eaa109381aefbcf5a49be FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a image_editor_common: d6f6644ae4a6de80481e89fe6d0a8c49e30b4b43 image_gallery_saver: cb43cc43141711190510e92c460eb1655cd343cb + libwebp: 1786c9f4ff8a279e4dac1e8f385004d5fc253009 + Mantle: c5aa8794a29a022dfbbfc9799af95f477a69b62d package_info_plus: fd030dabf36271f146f1f3beacd48f564b0f17f7 path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8 permission_handler_apple: e76247795d700c14ea09e3a2d8855d41ee80a2e6 receive_sharing_intent: c0d87310754e74c0f9542947e7cbdf3a0335a3b1 SDWebImage: cb032eba469c54e0000e78bcb0a13cdde0a52798 + SDWebImageWebPCoder: 295a6573c512f54ad2dd58098e64e17dcf008499 share_plus: 599aa54e4ea31d4b4c0e9c911bcc26c55e791028 shared_preferences_foundation: e2dae3258e06f44cc55f49d42024fd8dd03c590c sqflite: 31f7eba61e3074736dff8807a9b41581e4f7f15a diff --git a/lib/router/app_router.gr.dart b/lib/router/app_router.gr.dart index 507d1a474..5b179e22b 100644 --- a/lib/router/app_router.gr.dart +++ b/lib/router/app_router.gr.dart @@ -15,23 +15,13 @@ abstract class _$AppRouter extends RootStackRouter { @override final Map pagesMap = { - AnnouncementRoute.name: (routeData) { - final args = routeData.argsAs(); - return AutoRoutePage( - routeData: routeData, - child: AnnouncementPage( - key: args.key, - account: args.account, - ), - ); - }, - AntennaNotesRoute.name: (routeData) { - final args = routeData.argsAs(); + NotesAfterRenoteRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: AntennaNotesPage( + child: NotesAfterRenotePage( key: args.key, - antenna: args.antenna, + note: args.note, account: args.account, ), ); @@ -46,27 +36,33 @@ abstract class _$AppRouter extends RootStackRouter { ), ); }, - ChannelsRoute.name: (routeData) { - final args = routeData.argsAs(); + AntennaNotesRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: ChannelsPage( + child: AntennaNotesPage( key: args.key, + antenna: args.antenna, account: args.account, ), ); }, - ChannelDetailRoute.name: (routeData) { - final args = routeData.argsAs(); + NotificationRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: ChannelDetailPage( + child: NotificationPage( key: args.key, account: args.account, - channelId: args.channelId, ), ); }, + LoginRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const LoginPage(), + ); + }, ClipDetailRoute.name: (routeData) { final args = routeData.argsAs(); return AutoRoutePage( @@ -88,230 +84,227 @@ abstract class _$AppRouter extends RootStackRouter { ), ); }, - ExploreRoute.name: (routeData) { - final args = routeData.argsAs(); + NoteCreateRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: ExplorePage( + child: NoteCreatePage( key: args.key, - account: args.account, + initialAccount: args.initialAccount, + initialText: args.initialText, + initialMediaFiles: args.initialMediaFiles, + channel: args.channel, + reply: args.reply, + renote: args.renote, + note: args.note, + noteCreationMode: args.noteCreationMode, ), ); }, - ExploreRoleUsersRoute.name: (routeData) { - final args = routeData.argsAs(); + HashtagRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: ExploreRoleUsersPage( + child: HashtagPage( key: args.key, - item: args.item, + hashtag: args.hashtag, account: args.account, ), ); }, - FavoritedNoteRoute.name: (routeData) { - final args = routeData.argsAs(); + UserFolloweeRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: FavoritedNotePage( + child: UserFolloweePage( key: args.key, + userId: args.userId, account: args.account, ), ); }, - FederationRoute.name: (routeData) { - final args = routeData.argsAs(); + UserRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: FederationPage( + child: UserPage( key: args.key, + userId: args.userId, account: args.account, - host: args.host, ), ); }, - HashtagRoute.name: (routeData) { - final args = routeData.argsAs(); + UserFollowerRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: HashtagPage( + child: UserFollowerPage( key: args.key, - hashtag: args.hashtag, + userId: args.userId, account: args.account, ), ); }, - LoginRoute.name: (routeData) { - return AutoRoutePage( + PhotoEditRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( routeData: routeData, - child: const LoginPage(), + child: PhotoEditPage( + account: args.account, + file: args.file, + onSubmit: args.onSubmit, + key: args.key, + ), ); }, - NotesAfterRenoteRoute.name: (routeData) { - final args = routeData.argsAs(); + AnnouncementRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: NotesAfterRenotePage( + child: AnnouncementPage( key: args.key, - note: args.note, account: args.account, ), ); }, - NoteCreateRoute.name: (routeData) { - final args = routeData.argsAs(); + SplashRoute.name: (routeData) { return AutoRoutePage( routeData: routeData, - child: NoteCreatePage( - key: args.key, - initialAccount: args.initialAccount, - initialText: args.initialText, - initialMediaFiles: args.initialMediaFiles, - channel: args.channel, - reply: args.reply, - renote: args.renote, - note: args.note, - noteCreationMode: args.noteCreationMode, - ), + child: const SplashPage(), ); }, - NoteDetailRoute.name: (routeData) { - final args = routeData.argsAs(); + SeveralAccountGeneralSettingsRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: NoteDetailPage( + child: SeveralAccountGeneralSettingsPage( key: args.key, - note: args.note, account: args.account, ), ); }, - NotificationRoute.name: (routeData) { - final args = routeData.argsAs(); + SeveralAccountSettingsRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: NotificationPage( + child: SeveralAccountSettingsPage( key: args.key, account: args.account, ), ); }, - PhotoEditRoute.name: (routeData) { - final args = routeData.argsAs(); - return AutoRoutePage( + InstanceMuteRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( routeData: routeData, - child: PhotoEditPage( - account: args.account, - file: args.file, - onSubmit: args.onSubmit, + child: InstanceMutePage( key: args.key, + account: args.account, ), ); }, - SearchRoute.name: (routeData) { - final args = routeData.argsAs(); + HardMuteRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: SearchPage( + child: HardMutePage( key: args.key, - initialSearchText: args.initialSearchText, account: args.account, ), ); }, - AccountListRoute.name: (routeData) { - return AutoRoutePage( - routeData: routeData, - child: const AccountListPage(), - ); - }, - AppInfoRoute.name: (routeData) { - return AutoRoutePage( - routeData: routeData, - child: const AppInfoPage(), - ); - }, - GeneralSettingsRoute.name: (routeData) { - return AutoRoutePage( - routeData: routeData, - child: const GeneralSettingsPage(), - ); - }, - ImportExportRoute.name: (routeData) { + ReactionDeckRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: const ImportExportPage(), + child: ReactionDeckPage( + key: args.key, + account: args.account, + ), ); }, - SettingsRoute.name: (routeData) { + UsersListTimelineRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: const SettingsPage(), + child: UsersListTimelinePage( + args.account, + args.list, + key: args.key, + ), ); }, - TabSettingsListRoute.name: (routeData) { + UsersListRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: const TabSettingsListPage(), + child: UsersListPage( + args.account, + key: args.key, + ), ); }, - TabSettingsRoute.name: (routeData) { - final args = routeData.argsAs( - orElse: () => const TabSettingsRouteArgs()); + UsersListDetailRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: TabSettingsPage( + child: UsersListDetailPage( key: args.key, - tabIndex: args.tabIndex, + account: args.account, + listId: args.listId, ), ); }, - HardMuteRoute.name: (routeData) { - final args = routeData.argsAs(); + ChannelDetailRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: HardMutePage( + child: ChannelDetailPage( key: args.key, account: args.account, + channelId: args.channelId, ), ); }, - InstanceMuteRoute.name: (routeData) { - final args = routeData.argsAs(); + ChannelsRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: InstanceMutePage( + child: ChannelsPage( key: args.key, account: args.account, ), ); }, - ReactionDeckRoute.name: (routeData) { - final args = routeData.argsAs(); + FederationRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: ReactionDeckPage( + child: FederationPage( key: args.key, account: args.account, + host: args.host, ), ); }, - SeveralAccountGeneralSettingsRoute.name: (routeData) { - final args = routeData.argsAs(); + NoteDetailRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: SeveralAccountGeneralSettingsPage( + child: NoteDetailPage( key: args.key, + note: args.note, account: args.account, ), ); }, - SeveralAccountSettingsRoute.name: (routeData) { - final args = routeData.argsAs(); + SearchRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: SeveralAccountSettingsPage( + child: SearchPage( key: args.key, + initialSearchText: args.initialSearchText, account: args.account, ), ); @@ -328,62 +321,70 @@ abstract class _$AppRouter extends RootStackRouter { ), ); }, - SplashRoute.name: (routeData) { + ImportExportRoute.name: (routeData) { return AutoRoutePage( routeData: routeData, - child: const SplashPage(), + child: const ImportExportPage(), ); }, - UsersListRoute.name: (routeData) { - final args = routeData.argsAs(); + GeneralSettingsRoute.name: (routeData) { return AutoRoutePage( routeData: routeData, - child: UsersListPage( - args.account, - key: args.key, - ), + child: const GeneralSettingsPage(), ); }, - UsersListTimelineRoute.name: (routeData) { - final args = routeData.argsAs(); + TabSettingsRoute.name: (routeData) { + final args = routeData.argsAs( + orElse: () => const TabSettingsRouteArgs()); return AutoRoutePage( routeData: routeData, - child: UsersListTimelinePage( - args.account, - args.list, + child: TabSettingsPage( key: args.key, + tabIndex: args.tabIndex, ), ); }, - UserFolloweeRoute.name: (routeData) { - final args = routeData.argsAs(); + TabSettingsListRoute.name: (routeData) { return AutoRoutePage( routeData: routeData, - child: UserFolloweePage( - key: args.key, - userId: args.userId, - account: args.account, - ), + child: const TabSettingsListPage(), ); }, - UserFollowerRoute.name: (routeData) { - final args = routeData.argsAs(); + AppInfoRoute.name: (routeData) { return AutoRoutePage( routeData: routeData, - child: UserFollowerPage( + child: const AppInfoPage(), + ); + }, + SettingsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const SettingsPage(), + ); + }, + AccountListRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const AccountListPage(), + ); + }, + ExploreRoleUsersRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: ExploreRoleUsersPage( key: args.key, - userId: args.userId, + item: args.item, account: args.account, ), ); }, - UserRoute.name: (routeData) { - final args = routeData.argsAs(); + ExploreRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: UserPage( + child: ExplorePage( key: args.key, - userId: args.userId, account: args.account, ), ); @@ -398,14 +399,13 @@ abstract class _$AppRouter extends RootStackRouter { ), ); }, - UsersListDetailRoute.name: (routeData) { - final args = routeData.argsAs(); + FavoritedNoteRoute.name: (routeData) { + final args = routeData.argsAs(); return AutoRoutePage( routeData: routeData, - child: UsersListDetailPage( + child: FavoritedNotePage( key: args.key, account: args.account, - listId: args.listId, ), ); }, @@ -413,83 +413,45 @@ abstract class _$AppRouter extends RootStackRouter { } /// generated route for -/// [AnnouncementPage] -class AnnouncementRoute extends PageRouteInfo { - AnnouncementRoute({ - Key? key, - required Account account, - List? children, - }) : super( - AnnouncementRoute.name, - args: AnnouncementRouteArgs( - key: key, - account: account, - ), - initialChildren: children, - ); - - static const String name = 'AnnouncementRoute'; - - static const PageInfo page = - PageInfo(name); -} - -class AnnouncementRouteArgs { - const AnnouncementRouteArgs({ - this.key, - required this.account, - }); - - final Key? key; - - final Account account; - - @override - String toString() { - return 'AnnouncementRouteArgs{key: $key, account: $account}'; - } -} - -/// generated route for -/// [AntennaNotesPage] -class AntennaNotesRoute extends PageRouteInfo { - AntennaNotesRoute({ +/// [NotesAfterRenotePage] +class NotesAfterRenoteRoute extends PageRouteInfo { + NotesAfterRenoteRoute({ Key? key, - required Antenna antenna, + required Note note, required Account account, List? children, }) : super( - AntennaNotesRoute.name, - args: AntennaNotesRouteArgs( + NotesAfterRenoteRoute.name, + args: NotesAfterRenoteRouteArgs( key: key, - antenna: antenna, + note: note, account: account, ), initialChildren: children, ); - static const String name = 'AntennaNotesRoute'; + static const String name = 'NotesAfterRenoteRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class AntennaNotesRouteArgs { - const AntennaNotesRouteArgs({ +class NotesAfterRenoteRouteArgs { + const NotesAfterRenoteRouteArgs({ this.key, - required this.antenna, + required this.note, required this.account, }); final Key? key; - final Antenna antenna; + final Note note; final Account account; @override String toString() { - return 'AntennaNotesRouteArgs{key: $key, antenna: $antenna, account: $account}'; + return 'NotesAfterRenoteRouteArgs{key: $key, note: $note, account: $account}'; } } @@ -532,86 +494,100 @@ class AntennaRouteArgs { } /// generated route for -/// [ChannelsPage] -class ChannelsRoute extends PageRouteInfo { - ChannelsRoute({ +/// [AntennaNotesPage] +class AntennaNotesRoute extends PageRouteInfo { + AntennaNotesRoute({ Key? key, + required Antenna antenna, required Account account, List? children, }) : super( - ChannelsRoute.name, - args: ChannelsRouteArgs( + AntennaNotesRoute.name, + args: AntennaNotesRouteArgs( key: key, + antenna: antenna, account: account, ), initialChildren: children, ); - static const String name = 'ChannelsRoute'; + static const String name = 'AntennaNotesRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class ChannelsRouteArgs { - const ChannelsRouteArgs({ +class AntennaNotesRouteArgs { + const AntennaNotesRouteArgs({ this.key, + required this.antenna, required this.account, }); final Key? key; + final Antenna antenna; + final Account account; @override String toString() { - return 'ChannelsRouteArgs{key: $key, account: $account}'; + return 'AntennaNotesRouteArgs{key: $key, antenna: $antenna, account: $account}'; } } /// generated route for -/// [ChannelDetailPage] -class ChannelDetailRoute extends PageRouteInfo { - ChannelDetailRoute({ +/// [NotificationPage] +class NotificationRoute extends PageRouteInfo { + NotificationRoute({ Key? key, required Account account, - required String channelId, List? children, }) : super( - ChannelDetailRoute.name, - args: ChannelDetailRouteArgs( + NotificationRoute.name, + args: NotificationRouteArgs( key: key, account: account, - channelId: channelId, ), initialChildren: children, ); - static const String name = 'ChannelDetailRoute'; + static const String name = 'NotificationRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class ChannelDetailRouteArgs { - const ChannelDetailRouteArgs({ +class NotificationRouteArgs { + const NotificationRouteArgs({ this.key, required this.account, - required this.channelId, }); final Key? key; final Account account; - final String channelId; - @override String toString() { - return 'ChannelDetailRouteArgs{key: $key, account: $account, channelId: $channelId}'; + return 'NotificationRouteArgs{key: $key, account: $account}'; } } +/// generated route for +/// [LoginPage] +class LoginRoute extends PageRouteInfo { + const LoginRoute({List? children}) + : super( + LoginRoute.name, + initialChildren: children, + ); + + static const String name = 'LoginRoute'; + + static const PageInfo page = PageInfo(name); +} + /// generated route for /// [ClipDetailPage] class ClipDetailRoute extends PageRouteInfo { @@ -694,407 +670,451 @@ class ClipListRouteArgs { } /// generated route for -/// [ExplorePage] -class ExploreRoute extends PageRouteInfo { - ExploreRoute({ +/// [NoteCreatePage] +class NoteCreateRoute extends PageRouteInfo { + NoteCreateRoute({ Key? key, - required Account account, + required Account initialAccount, + String? initialText, + List? initialMediaFiles, + CommunityChannel? channel, + Note? reply, + Note? renote, + Note? note, + NoteCreationMode? noteCreationMode, List? children, }) : super( - ExploreRoute.name, - args: ExploreRouteArgs( + NoteCreateRoute.name, + args: NoteCreateRouteArgs( key: key, - account: account, + initialAccount: initialAccount, + initialText: initialText, + initialMediaFiles: initialMediaFiles, + channel: channel, + reply: reply, + renote: renote, + note: note, + noteCreationMode: noteCreationMode, ), initialChildren: children, ); - static const String name = 'ExploreRoute'; + static const String name = 'NoteCreateRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class ExploreRouteArgs { - const ExploreRouteArgs({ +class NoteCreateRouteArgs { + const NoteCreateRouteArgs({ this.key, - required this.account, + required this.initialAccount, + this.initialText, + this.initialMediaFiles, + this.channel, + this.reply, + this.renote, + this.note, + this.noteCreationMode, }); final Key? key; - final Account account; + final Account initialAccount; + + final String? initialText; + + final List? initialMediaFiles; + + final CommunityChannel? channel; + + final Note? reply; + + final Note? renote; + + final Note? note; + + final NoteCreationMode? noteCreationMode; @override String toString() { - return 'ExploreRouteArgs{key: $key, account: $account}'; + return 'NoteCreateRouteArgs{key: $key, initialAccount: $initialAccount, initialText: $initialText, initialMediaFiles: $initialMediaFiles, channel: $channel, reply: $reply, renote: $renote, note: $note, noteCreationMode: $noteCreationMode}'; } } /// generated route for -/// [ExploreRoleUsersPage] -class ExploreRoleUsersRoute extends PageRouteInfo { - ExploreRoleUsersRoute({ +/// [HashtagPage] +class HashtagRoute extends PageRouteInfo { + HashtagRoute({ Key? key, - required RolesListResponse item, + required String hashtag, required Account account, List? children, }) : super( - ExploreRoleUsersRoute.name, - args: ExploreRoleUsersRouteArgs( + HashtagRoute.name, + args: HashtagRouteArgs( key: key, - item: item, + hashtag: hashtag, account: account, ), initialChildren: children, ); - static const String name = 'ExploreRoleUsersRoute'; + static const String name = 'HashtagRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class ExploreRoleUsersRouteArgs { - const ExploreRoleUsersRouteArgs({ +class HashtagRouteArgs { + const HashtagRouteArgs({ this.key, - required this.item, + required this.hashtag, required this.account, }); final Key? key; - final RolesListResponse item; + final String hashtag; final Account account; @override String toString() { - return 'ExploreRoleUsersRouteArgs{key: $key, item: $item, account: $account}'; + return 'HashtagRouteArgs{key: $key, hashtag: $hashtag, account: $account}'; } } /// generated route for -/// [FavoritedNotePage] -class FavoritedNoteRoute extends PageRouteInfo { - FavoritedNoteRoute({ +/// [UserFolloweePage] +class UserFolloweeRoute extends PageRouteInfo { + UserFolloweeRoute({ Key? key, + required String userId, required Account account, List? children, }) : super( - FavoritedNoteRoute.name, - args: FavoritedNoteRouteArgs( + UserFolloweeRoute.name, + args: UserFolloweeRouteArgs( key: key, + userId: userId, account: account, ), initialChildren: children, ); - static const String name = 'FavoritedNoteRoute'; + static const String name = 'UserFolloweeRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class FavoritedNoteRouteArgs { - const FavoritedNoteRouteArgs({ +class UserFolloweeRouteArgs { + const UserFolloweeRouteArgs({ this.key, + required this.userId, required this.account, }); final Key? key; + final String userId; + final Account account; @override String toString() { - return 'FavoritedNoteRouteArgs{key: $key, account: $account}'; + return 'UserFolloweeRouteArgs{key: $key, userId: $userId, account: $account}'; } } /// generated route for -/// [FederationPage] -class FederationRoute extends PageRouteInfo { - FederationRoute({ +/// [UserPage] +class UserRoute extends PageRouteInfo { + UserRoute({ Key? key, + required String userId, required Account account, - required String host, List? children, }) : super( - FederationRoute.name, - args: FederationRouteArgs( + UserRoute.name, + args: UserRouteArgs( key: key, + userId: userId, account: account, - host: host, ), initialChildren: children, ); - static const String name = 'FederationRoute'; + static const String name = 'UserRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = PageInfo(name); } -class FederationRouteArgs { - const FederationRouteArgs({ +class UserRouteArgs { + const UserRouteArgs({ this.key, + required this.userId, required this.account, - required this.host, }); final Key? key; - final Account account; + final String userId; - final String host; + final Account account; @override String toString() { - return 'FederationRouteArgs{key: $key, account: $account, host: $host}'; + return 'UserRouteArgs{key: $key, userId: $userId, account: $account}'; } } /// generated route for -/// [HashtagPage] -class HashtagRoute extends PageRouteInfo { - HashtagRoute({ +/// [UserFollowerPage] +class UserFollowerRoute extends PageRouteInfo { + UserFollowerRoute({ Key? key, - required String hashtag, + required String userId, required Account account, List? children, }) : super( - HashtagRoute.name, - args: HashtagRouteArgs( + UserFollowerRoute.name, + args: UserFollowerRouteArgs( key: key, - hashtag: hashtag, + userId: userId, account: account, ), initialChildren: children, ); - static const String name = 'HashtagRoute'; + static const String name = 'UserFollowerRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class HashtagRouteArgs { - const HashtagRouteArgs({ +class UserFollowerRouteArgs { + const UserFollowerRouteArgs({ this.key, - required this.hashtag, + required this.userId, required this.account, }); final Key? key; - final String hashtag; + final String userId; final Account account; @override String toString() { - return 'HashtagRouteArgs{key: $key, hashtag: $hashtag, account: $account}'; + return 'UserFollowerRouteArgs{key: $key, userId: $userId, account: $account}'; } } /// generated route for -/// [LoginPage] -class LoginRoute extends PageRouteInfo { - const LoginRoute({List? children}) - : super( - LoginRoute.name, +/// [PhotoEditPage] +class PhotoEditRoute extends PageRouteInfo { + PhotoEditRoute({ + required Account account, + required MisskeyPostFile file, + required void Function(Uint8List) onSubmit, + Key? key, + List? children, + }) : super( + PhotoEditRoute.name, + args: PhotoEditRouteArgs( + account: account, + file: file, + onSubmit: onSubmit, + key: key, + ), initialChildren: children, ); - static const String name = 'LoginRoute'; + static const String name = 'PhotoEditRoute'; - static const PageInfo page = PageInfo(name); + static const PageInfo page = + PageInfo(name); +} + +class PhotoEditRouteArgs { + const PhotoEditRouteArgs({ + required this.account, + required this.file, + required this.onSubmit, + this.key, + }); + + final Account account; + + final MisskeyPostFile file; + + final void Function(Uint8List) onSubmit; + + final Key? key; + + @override + String toString() { + return 'PhotoEditRouteArgs{account: $account, file: $file, onSubmit: $onSubmit, key: $key}'; + } } /// generated route for -/// [NotesAfterRenotePage] -class NotesAfterRenoteRoute extends PageRouteInfo { - NotesAfterRenoteRoute({ +/// [AnnouncementPage] +class AnnouncementRoute extends PageRouteInfo { + AnnouncementRoute({ Key? key, - required Note note, required Account account, List? children, }) : super( - NotesAfterRenoteRoute.name, - args: NotesAfterRenoteRouteArgs( + AnnouncementRoute.name, + args: AnnouncementRouteArgs( key: key, - note: note, account: account, ), initialChildren: children, ); - static const String name = 'NotesAfterRenoteRoute'; + static const String name = 'AnnouncementRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class NotesAfterRenoteRouteArgs { - const NotesAfterRenoteRouteArgs({ +class AnnouncementRouteArgs { + const AnnouncementRouteArgs({ this.key, - required this.note, required this.account, }); final Key? key; - final Note note; - final Account account; @override String toString() { - return 'NotesAfterRenoteRouteArgs{key: $key, note: $note, account: $account}'; + return 'AnnouncementRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [NoteCreatePage] -class NoteCreateRoute extends PageRouteInfo { - NoteCreateRoute({ +/// [SplashPage] +class SplashRoute extends PageRouteInfo { + const SplashRoute({List? children}) + : super( + SplashRoute.name, + initialChildren: children, + ); + + static const String name = 'SplashRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [SeveralAccountGeneralSettingsPage] +class SeveralAccountGeneralSettingsRoute + extends PageRouteInfo { + SeveralAccountGeneralSettingsRoute({ Key? key, - required Account initialAccount, - String? initialText, - List? initialMediaFiles, - CommunityChannel? channel, - Note? reply, - Note? renote, - Note? note, - NoteCreationMode? noteCreationMode, + required Account account, List? children, }) : super( - NoteCreateRoute.name, - args: NoteCreateRouteArgs( + SeveralAccountGeneralSettingsRoute.name, + args: SeveralAccountGeneralSettingsRouteArgs( key: key, - initialAccount: initialAccount, - initialText: initialText, - initialMediaFiles: initialMediaFiles, - channel: channel, - reply: reply, - renote: renote, - note: note, - noteCreationMode: noteCreationMode, + account: account, ), initialChildren: children, ); - static const String name = 'NoteCreateRoute'; + static const String name = 'SeveralAccountGeneralSettingsRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class NoteCreateRouteArgs { - const NoteCreateRouteArgs({ +class SeveralAccountGeneralSettingsRouteArgs { + const SeveralAccountGeneralSettingsRouteArgs({ this.key, - required this.initialAccount, - this.initialText, - this.initialMediaFiles, - this.channel, - this.reply, - this.renote, - this.note, - this.noteCreationMode, + required this.account, }); final Key? key; - final Account initialAccount; - - final String? initialText; - - final List? initialMediaFiles; - - final CommunityChannel? channel; - - final Note? reply; - - final Note? renote; - - final Note? note; - - final NoteCreationMode? noteCreationMode; + final Account account; @override String toString() { - return 'NoteCreateRouteArgs{key: $key, initialAccount: $initialAccount, initialText: $initialText, initialMediaFiles: $initialMediaFiles, channel: $channel, reply: $reply, renote: $renote, note: $note, noteCreationMode: $noteCreationMode}'; + return 'SeveralAccountGeneralSettingsRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [NoteDetailPage] -class NoteDetailRoute extends PageRouteInfo { - NoteDetailRoute({ +/// [SeveralAccountSettingsPage] +class SeveralAccountSettingsRoute + extends PageRouteInfo { + SeveralAccountSettingsRoute({ Key? key, - required Note note, required Account account, List? children, }) : super( - NoteDetailRoute.name, - args: NoteDetailRouteArgs( + SeveralAccountSettingsRoute.name, + args: SeveralAccountSettingsRouteArgs( key: key, - note: note, account: account, ), initialChildren: children, ); - static const String name = 'NoteDetailRoute'; + static const String name = 'SeveralAccountSettingsRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class NoteDetailRouteArgs { - const NoteDetailRouteArgs({ +class SeveralAccountSettingsRouteArgs { + const SeveralAccountSettingsRouteArgs({ this.key, - required this.note, required this.account, }); final Key? key; - final Note note; - final Account account; @override String toString() { - return 'NoteDetailRouteArgs{key: $key, note: $note, account: $account}'; + return 'SeveralAccountSettingsRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [NotificationPage] -class NotificationRoute extends PageRouteInfo { - NotificationRoute({ +/// [InstanceMutePage] +class InstanceMuteRoute extends PageRouteInfo { + InstanceMuteRoute({ Key? key, required Account account, List? children, }) : super( - NotificationRoute.name, - args: NotificationRouteArgs( + InstanceMuteRoute.name, + args: InstanceMuteRouteArgs( key: key, account: account, ), initialChildren: children, ); - static const String name = 'NotificationRoute'; + static const String name = 'InstanceMuteRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class NotificationRouteArgs { - const NotificationRouteArgs({ +class InstanceMuteRouteArgs { + const InstanceMuteRouteArgs({ this.key, required this.account, }); @@ -1105,284 +1125,277 @@ class NotificationRouteArgs { @override String toString() { - return 'NotificationRouteArgs{key: $key, account: $account}'; + return 'InstanceMuteRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [PhotoEditPage] -class PhotoEditRoute extends PageRouteInfo { - PhotoEditRoute({ - required Account account, - required MisskeyPostFile file, - required void Function(Uint8List) onSubmit, +/// [HardMutePage] +class HardMuteRoute extends PageRouteInfo { + HardMuteRoute({ Key? key, + required Account account, List? children, }) : super( - PhotoEditRoute.name, - args: PhotoEditRouteArgs( - account: account, - file: file, - onSubmit: onSubmit, + HardMuteRoute.name, + args: HardMuteRouteArgs( key: key, + account: account, ), initialChildren: children, ); - static const String name = 'PhotoEditRoute'; + static const String name = 'HardMuteRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class PhotoEditRouteArgs { - const PhotoEditRouteArgs({ - required this.account, - required this.file, - required this.onSubmit, +class HardMuteRouteArgs { + const HardMuteRouteArgs({ this.key, + required this.account, }); - final Account account; - - final MisskeyPostFile file; - - final void Function(Uint8List) onSubmit; - final Key? key; + final Account account; + @override String toString() { - return 'PhotoEditRouteArgs{account: $account, file: $file, onSubmit: $onSubmit, key: $key}'; + return 'HardMuteRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [SearchPage] -class SearchRoute extends PageRouteInfo { - SearchRoute({ +/// [ReactionDeckPage] +class ReactionDeckRoute extends PageRouteInfo { + ReactionDeckRoute({ Key? key, - String? initialSearchText, required Account account, List? children, }) : super( - SearchRoute.name, - args: SearchRouteArgs( + ReactionDeckRoute.name, + args: ReactionDeckRouteArgs( key: key, - initialSearchText: initialSearchText, account: account, ), initialChildren: children, ); - static const String name = 'SearchRoute'; + static const String name = 'ReactionDeckRoute'; - static const PageInfo page = PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class SearchRouteArgs { - const SearchRouteArgs({ +class ReactionDeckRouteArgs { + const ReactionDeckRouteArgs({ this.key, - this.initialSearchText, required this.account, }); final Key? key; - final String? initialSearchText; - final Account account; @override String toString() { - return 'SearchRouteArgs{key: $key, initialSearchText: $initialSearchText, account: $account}'; + return 'ReactionDeckRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [AccountListPage] -class AccountListRoute extends PageRouteInfo { - const AccountListRoute({List? children}) - : super( - AccountListRoute.name, +/// [UsersListTimelinePage] +class UsersListTimelineRoute extends PageRouteInfo { + UsersListTimelineRoute({ + required Account account, + required UsersList list, + Key? key, + List? children, + }) : super( + UsersListTimelineRoute.name, + args: UsersListTimelineRouteArgs( + account: account, + list: list, + key: key, + ), initialChildren: children, ); - static const String name = 'AccountListRoute'; + static const String name = 'UsersListTimelineRoute'; - static const PageInfo page = PageInfo(name); + static const PageInfo page = + PageInfo(name); } -/// generated route for -/// [AppInfoPage] -class AppInfoRoute extends PageRouteInfo { - const AppInfoRoute({List? children}) - : super( - AppInfoRoute.name, - initialChildren: children, - ); - - static const String name = 'AppInfoRoute'; +class UsersListTimelineRouteArgs { + const UsersListTimelineRouteArgs({ + required this.account, + required this.list, + this.key, + }); - static const PageInfo page = PageInfo(name); -} + final Account account; -/// generated route for -/// [GeneralSettingsPage] -class GeneralSettingsRoute extends PageRouteInfo { - const GeneralSettingsRoute({List? children}) - : super( - GeneralSettingsRoute.name, - initialChildren: children, - ); + final UsersList list; - static const String name = 'GeneralSettingsRoute'; + final Key? key; - static const PageInfo page = PageInfo(name); + @override + String toString() { + return 'UsersListTimelineRouteArgs{account: $account, list: $list, key: $key}'; + } } /// generated route for -/// [ImportExportPage] -class ImportExportRoute extends PageRouteInfo { - const ImportExportRoute({List? children}) - : super( - ImportExportRoute.name, +/// [UsersListPage] +class UsersListRoute extends PageRouteInfo { + UsersListRoute({ + required Account account, + Key? key, + List? children, + }) : super( + UsersListRoute.name, + args: UsersListRouteArgs( + account: account, + key: key, + ), initialChildren: children, ); - static const String name = 'ImportExportRoute'; + static const String name = 'UsersListRoute'; - static const PageInfo page = PageInfo(name); + static const PageInfo page = + PageInfo(name); } -/// generated route for -/// [SettingsPage] -class SettingsRoute extends PageRouteInfo { - const SettingsRoute({List? children}) - : super( - SettingsRoute.name, - initialChildren: children, - ); - - static const String name = 'SettingsRoute'; - - static const PageInfo page = PageInfo(name); -} +class UsersListRouteArgs { + const UsersListRouteArgs({ + required this.account, + this.key, + }); -/// generated route for -/// [TabSettingsListPage] -class TabSettingsListRoute extends PageRouteInfo { - const TabSettingsListRoute({List? children}) - : super( - TabSettingsListRoute.name, - initialChildren: children, - ); + final Account account; - static const String name = 'TabSettingsListRoute'; + final Key? key; - static const PageInfo page = PageInfo(name); + @override + String toString() { + return 'UsersListRouteArgs{account: $account, key: $key}'; + } } /// generated route for -/// [TabSettingsPage] -class TabSettingsRoute extends PageRouteInfo { - TabSettingsRoute({ +/// [UsersListDetailPage] +class UsersListDetailRoute extends PageRouteInfo { + UsersListDetailRoute({ Key? key, - int? tabIndex, + required Account account, + required String listId, List? children, }) : super( - TabSettingsRoute.name, - args: TabSettingsRouteArgs( + UsersListDetailRoute.name, + args: UsersListDetailRouteArgs( key: key, - tabIndex: tabIndex, + account: account, + listId: listId, ), initialChildren: children, ); - static const String name = 'TabSettingsRoute'; + static const String name = 'UsersListDetailRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class TabSettingsRouteArgs { - const TabSettingsRouteArgs({ +class UsersListDetailRouteArgs { + const UsersListDetailRouteArgs({ this.key, - this.tabIndex, + required this.account, + required this.listId, }); final Key? key; - final int? tabIndex; + final Account account; + + final String listId; @override String toString() { - return 'TabSettingsRouteArgs{key: $key, tabIndex: $tabIndex}'; + return 'UsersListDetailRouteArgs{key: $key, account: $account, listId: $listId}'; } } /// generated route for -/// [HardMutePage] -class HardMuteRoute extends PageRouteInfo { - HardMuteRoute({ +/// [ChannelDetailPage] +class ChannelDetailRoute extends PageRouteInfo { + ChannelDetailRoute({ Key? key, required Account account, + required String channelId, List? children, }) : super( - HardMuteRoute.name, - args: HardMuteRouteArgs( + ChannelDetailRoute.name, + args: ChannelDetailRouteArgs( key: key, account: account, + channelId: channelId, ), initialChildren: children, ); - static const String name = 'HardMuteRoute'; + static const String name = 'ChannelDetailRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class HardMuteRouteArgs { - const HardMuteRouteArgs({ +class ChannelDetailRouteArgs { + const ChannelDetailRouteArgs({ this.key, required this.account, + required this.channelId, }); final Key? key; final Account account; + final String channelId; + @override String toString() { - return 'HardMuteRouteArgs{key: $key, account: $account}'; + return 'ChannelDetailRouteArgs{key: $key, account: $account, channelId: $channelId}'; } } /// generated route for -/// [InstanceMutePage] -class InstanceMuteRoute extends PageRouteInfo { - InstanceMuteRoute({ +/// [ChannelsPage] +class ChannelsRoute extends PageRouteInfo { + ChannelsRoute({ Key? key, required Account account, List? children, }) : super( - InstanceMuteRoute.name, - args: InstanceMuteRouteArgs( + ChannelsRoute.name, + args: ChannelsRouteArgs( key: key, account: account, ), initialChildren: children, ); - static const String name = 'InstanceMuteRoute'; + static const String name = 'ChannelsRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class InstanceMuteRouteArgs { - const InstanceMuteRouteArgs({ +class ChannelsRouteArgs { + const ChannelsRouteArgs({ this.key, required this.account, }); @@ -1393,123 +1406,135 @@ class InstanceMuteRouteArgs { @override String toString() { - return 'InstanceMuteRouteArgs{key: $key, account: $account}'; + return 'ChannelsRouteArgs{key: $key, account: $account}'; } } /// generated route for -/// [ReactionDeckPage] -class ReactionDeckRoute extends PageRouteInfo { - ReactionDeckRoute({ +/// [FederationPage] +class FederationRoute extends PageRouteInfo { + FederationRoute({ Key? key, required Account account, + required String host, List? children, }) : super( - ReactionDeckRoute.name, - args: ReactionDeckRouteArgs( + FederationRoute.name, + args: FederationRouteArgs( key: key, account: account, + host: host, ), initialChildren: children, ); - static const String name = 'ReactionDeckRoute'; + static const String name = 'FederationRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class ReactionDeckRouteArgs { - const ReactionDeckRouteArgs({ +class FederationRouteArgs { + const FederationRouteArgs({ this.key, required this.account, + required this.host, }); final Key? key; final Account account; + final String host; + @override String toString() { - return 'ReactionDeckRouteArgs{key: $key, account: $account}'; + return 'FederationRouteArgs{key: $key, account: $account, host: $host}'; } } /// generated route for -/// [SeveralAccountGeneralSettingsPage] -class SeveralAccountGeneralSettingsRoute - extends PageRouteInfo { - SeveralAccountGeneralSettingsRoute({ +/// [NoteDetailPage] +class NoteDetailRoute extends PageRouteInfo { + NoteDetailRoute({ Key? key, + required Note note, required Account account, List? children, }) : super( - SeveralAccountGeneralSettingsRoute.name, - args: SeveralAccountGeneralSettingsRouteArgs( + NoteDetailRoute.name, + args: NoteDetailRouteArgs( key: key, + note: note, account: account, ), initialChildren: children, ); - static const String name = 'SeveralAccountGeneralSettingsRoute'; + static const String name = 'NoteDetailRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class SeveralAccountGeneralSettingsRouteArgs { - const SeveralAccountGeneralSettingsRouteArgs({ +class NoteDetailRouteArgs { + const NoteDetailRouteArgs({ this.key, + required this.note, required this.account, }); final Key? key; + final Note note; + final Account account; @override String toString() { - return 'SeveralAccountGeneralSettingsRouteArgs{key: $key, account: $account}'; + return 'NoteDetailRouteArgs{key: $key, note: $note, account: $account}'; } } /// generated route for -/// [SeveralAccountSettingsPage] -class SeveralAccountSettingsRoute - extends PageRouteInfo { - SeveralAccountSettingsRoute({ +/// [SearchPage] +class SearchRoute extends PageRouteInfo { + SearchRoute({ Key? key, + String? initialSearchText, required Account account, List? children, }) : super( - SeveralAccountSettingsRoute.name, - args: SeveralAccountSettingsRouteArgs( + SearchRoute.name, + args: SearchRouteArgs( key: key, + initialSearchText: initialSearchText, account: account, ), initialChildren: children, ); - static const String name = 'SeveralAccountSettingsRoute'; + static const String name = 'SearchRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = PageInfo(name); } -class SeveralAccountSettingsRouteArgs { - const SeveralAccountSettingsRouteArgs({ +class SearchRouteArgs { + const SearchRouteArgs({ this.key, + this.initialSearchText, required this.account, }); final Key? key; + final String? initialSearchText; + final Account account; @override String toString() { - return 'SeveralAccountSettingsRouteArgs{key: $key, account: $account}'; + return 'SearchRouteArgs{key: $key, initialSearchText: $initialSearchText, account: $account}'; } } @@ -1558,225 +1583,205 @@ class SharingAccountSelectRouteArgs { } /// generated route for -/// [SplashPage] -class SplashRoute extends PageRouteInfo { - const SplashRoute({List? children}) +/// [ImportExportPage] +class ImportExportRoute extends PageRouteInfo { + const ImportExportRoute({List? children}) : super( - SplashRoute.name, + ImportExportRoute.name, initialChildren: children, ); - static const String name = 'SplashRoute'; + static const String name = 'ImportExportRoute'; static const PageInfo page = PageInfo(name); } /// generated route for -/// [UsersListPage] -class UsersListRoute extends PageRouteInfo { - UsersListRoute({ - required Account account, +/// [GeneralSettingsPage] +class GeneralSettingsRoute extends PageRouteInfo { + const GeneralSettingsRoute({List? children}) + : super( + GeneralSettingsRoute.name, + initialChildren: children, + ); + + static const String name = 'GeneralSettingsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [TabSettingsPage] +class TabSettingsRoute extends PageRouteInfo { + TabSettingsRoute({ Key? key, + int? tabIndex, List? children, }) : super( - UsersListRoute.name, - args: UsersListRouteArgs( - account: account, + TabSettingsRoute.name, + args: TabSettingsRouteArgs( key: key, + tabIndex: tabIndex, ), initialChildren: children, ); - static const String name = 'UsersListRoute'; + static const String name = 'TabSettingsRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class UsersListRouteArgs { - const UsersListRouteArgs({ - required this.account, +class TabSettingsRouteArgs { + const TabSettingsRouteArgs({ this.key, + this.tabIndex, }); - final Account account; - final Key? key; + final int? tabIndex; + @override String toString() { - return 'UsersListRouteArgs{account: $account, key: $key}'; + return 'TabSettingsRouteArgs{key: $key, tabIndex: $tabIndex}'; } } /// generated route for -/// [UsersListTimelinePage] -class UsersListTimelineRoute extends PageRouteInfo { - UsersListTimelineRoute({ - required Account account, - required UsersList list, - Key? key, - List? children, - }) : super( - UsersListTimelineRoute.name, - args: UsersListTimelineRouteArgs( - account: account, - list: list, - key: key, - ), +/// [TabSettingsListPage] +class TabSettingsListRoute extends PageRouteInfo { + const TabSettingsListRoute({List? children}) + : super( + TabSettingsListRoute.name, initialChildren: children, ); - static const String name = 'UsersListTimelineRoute'; + static const String name = 'TabSettingsListRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = PageInfo(name); } -class UsersListTimelineRouteArgs { - const UsersListTimelineRouteArgs({ - required this.account, - required this.list, - this.key, - }); - - final Account account; - - final UsersList list; +/// generated route for +/// [AppInfoPage] +class AppInfoRoute extends PageRouteInfo { + const AppInfoRoute({List? children}) + : super( + AppInfoRoute.name, + initialChildren: children, + ); - final Key? key; + static const String name = 'AppInfoRoute'; - @override - String toString() { - return 'UsersListTimelineRouteArgs{account: $account, list: $list, key: $key}'; - } + static const PageInfo page = PageInfo(name); } /// generated route for -/// [UserFolloweePage] -class UserFolloweeRoute extends PageRouteInfo { - UserFolloweeRoute({ - Key? key, - required String userId, - required Account account, - List? children, - }) : super( - UserFolloweeRoute.name, - args: UserFolloweeRouteArgs( - key: key, - userId: userId, - account: account, - ), +/// [SettingsPage] +class SettingsRoute extends PageRouteInfo { + const SettingsRoute({List? children}) + : super( + SettingsRoute.name, initialChildren: children, ); - static const String name = 'UserFolloweeRoute'; + static const String name = 'SettingsRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = PageInfo(name); } -class UserFolloweeRouteArgs { - const UserFolloweeRouteArgs({ - this.key, - required this.userId, - required this.account, - }); - - final Key? key; - - final String userId; +/// generated route for +/// [AccountListPage] +class AccountListRoute extends PageRouteInfo { + const AccountListRoute({List? children}) + : super( + AccountListRoute.name, + initialChildren: children, + ); - final Account account; + static const String name = 'AccountListRoute'; - @override - String toString() { - return 'UserFolloweeRouteArgs{key: $key, userId: $userId, account: $account}'; - } + static const PageInfo page = PageInfo(name); } /// generated route for -/// [UserFollowerPage] -class UserFollowerRoute extends PageRouteInfo { - UserFollowerRoute({ +/// [ExploreRoleUsersPage] +class ExploreRoleUsersRoute extends PageRouteInfo { + ExploreRoleUsersRoute({ Key? key, - required String userId, + required RolesListResponse item, required Account account, List? children, }) : super( - UserFollowerRoute.name, - args: UserFollowerRouteArgs( + ExploreRoleUsersRoute.name, + args: ExploreRoleUsersRouteArgs( key: key, - userId: userId, + item: item, account: account, ), initialChildren: children, ); - static const String name = 'UserFollowerRoute'; + static const String name = 'ExploreRoleUsersRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class UserFollowerRouteArgs { - const UserFollowerRouteArgs({ +class ExploreRoleUsersRouteArgs { + const ExploreRoleUsersRouteArgs({ this.key, - required this.userId, + required this.item, required this.account, }); final Key? key; - final String userId; + final RolesListResponse item; final Account account; @override String toString() { - return 'UserFollowerRouteArgs{key: $key, userId: $userId, account: $account}'; + return 'ExploreRoleUsersRouteArgs{key: $key, item: $item, account: $account}'; } } /// generated route for -/// [UserPage] -class UserRoute extends PageRouteInfo { - UserRoute({ +/// [ExplorePage] +class ExploreRoute extends PageRouteInfo { + ExploreRoute({ Key? key, - required String userId, required Account account, List? children, }) : super( - UserRoute.name, - args: UserRouteArgs( + ExploreRoute.name, + args: ExploreRouteArgs( key: key, - userId: userId, account: account, ), initialChildren: children, ); - static const String name = 'UserRoute'; + static const String name = 'ExploreRoute'; - static const PageInfo page = PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class UserRouteArgs { - const UserRouteArgs({ +class ExploreRouteArgs { + const ExploreRouteArgs({ this.key, - required this.userId, required this.account, }); final Key? key; - final String userId; - final Account account; @override String toString() { - return 'UserRouteArgs{key: $key, userId: $userId, account: $account}'; + return 'ExploreRouteArgs{key: $key, account: $account}'; } } @@ -1819,44 +1824,39 @@ class TimeLineRouteArgs { } /// generated route for -/// [UsersListDetailPage] -class UsersListDetailRoute extends PageRouteInfo { - UsersListDetailRoute({ +/// [FavoritedNotePage] +class FavoritedNoteRoute extends PageRouteInfo { + FavoritedNoteRoute({ Key? key, required Account account, - required String listId, List? children, }) : super( - UsersListDetailRoute.name, - args: UsersListDetailRouteArgs( + FavoritedNoteRoute.name, + args: FavoritedNoteRouteArgs( key: key, account: account, - listId: listId, ), initialChildren: children, ); - static const String name = 'UsersListDetailRoute'; + static const String name = 'FavoritedNoteRoute'; - static const PageInfo page = - PageInfo(name); + static const PageInfo page = + PageInfo(name); } -class UsersListDetailRouteArgs { - const UsersListDetailRouteArgs({ +class FavoritedNoteRouteArgs { + const FavoritedNoteRouteArgs({ this.key, required this.account, - required this.listId, }); final Key? key; final Account account; - final String listId; - @override String toString() { - return 'UsersListDetailRouteArgs{key: $key, account: $account, listId: $listId}'; + return 'FavoritedNoteRouteArgs{key: $key, account: $account}'; } } diff --git a/test/test_util/mock.dart b/test/test_util/mock.dart index 91f2e15f5..0d5a23601 100644 --- a/test/test_util/mock.dart +++ b/test/test_util/mock.dart @@ -1,3 +1,5 @@ +import 'dart:io'; + import 'package:dio/dio.dart'; import 'package:file_picker/file_picker.dart'; import 'package:miria/repository/account_settings_repository.dart'; @@ -18,17 +20,28 @@ import 'package:plugin_platform_interface/plugin_platform_interface.dart'; // API MockSpec(), - MockSpec(), - MockSpec(), - MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), MockSpec(), + MockSpec(), MockSpec(), MockSpec(), MockSpec(), + MockSpec(), + MockSpec(), MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), + MockSpec(), // プラグインとか MockSpec(), + MockSpec(), MockSpec(as: #MockFilePickerPlatform) ]) // ignore: unused_import diff --git a/test/test_util/mock.mocks.dart b/test/test_util/mock.mocks.dart index 44837723d..edbf9a12d 100644 --- a/test/test_util/mock.mocks.dart +++ b/test/test_util/mock.mocks.dart @@ -3,10 +3,10 @@ // Do not manually edit this file. // ignore_for_file: no_leading_underscores_for_library_prefixes -import 'dart:async' as _i16; -import 'dart:io' as _i23; +import 'dart:async' as _i17; +import 'dart:io' as _i14; import 'dart:typed_data' as _i24; -import 'dart:ui' as _i18; +import 'dart:ui' as _i19; import 'package:dio/dio.dart' as _i25; import 'package:dio/src/adapter.dart' as _i10; @@ -16,15 +16,15 @@ import 'package:dio/src/options.dart' as _i9; import 'package:dio/src/response.dart' as _i13; import 'package:dio/src/transformer.dart' as _i11; import 'package:file_picker/file_picker.dart' as _i28; -import 'package:miria/model/account.dart' as _i17; +import 'package:miria/model/account.dart' as _i18; import 'package:miria/model/account_settings.dart' as _i2; import 'package:miria/model/general_settings.dart' as _i3; -import 'package:miria/model/misskey_emoji_data.dart' as _i21; -import 'package:miria/model/tab_setting.dart' as _i15; -import 'package:miria/repository/account_settings_repository.dart' as _i19; -import 'package:miria/repository/emoji_repository.dart' as _i20; -import 'package:miria/repository/general_settings_repository.dart' as _i22; -import 'package:miria/repository/tab_settings_repository.dart' as _i14; +import 'package:miria/model/misskey_emoji_data.dart' as _i22; +import 'package:miria/model/tab_setting.dart' as _i16; +import 'package:miria/repository/account_settings_repository.dart' as _i20; +import 'package:miria/repository/emoji_repository.dart' as _i21; +import 'package:miria/repository/general_settings_repository.dart' as _i23; +import 'package:miria/repository/tab_settings_repository.dart' as _i15; import 'package:misskey_dart/misskey_dart.dart' as _i6; import 'package:misskey_dart/src/data/ping_response.dart' as _i8; import 'package:misskey_dart/src/data/stats_response.dart' as _i7; @@ -329,9 +329,8 @@ class _FakeSocketController_26 extends _i1.SmartFake ); } -class _FakeMisskeyNotesReactions_27 extends _i1.SmartFake - implements _i6.MisskeyNotesReactions { - _FakeMisskeyNotesReactions_27( +class _FakeAntenna_27 extends _i1.SmartFake implements _i6.Antenna { + _FakeAntenna_27( Object parent, Invocation parentInvocation, ) : super( @@ -340,9 +339,9 @@ class _FakeMisskeyNotesReactions_27 extends _i1.SmartFake ); } -class _FakeMisskeyNotesFavorites_28 extends _i1.SmartFake - implements _i6.MisskeyNotesFavorites { - _FakeMisskeyNotesFavorites_28( +class _FakeApShowResponse_28 extends _i1.SmartFake + implements _i6.ApShowResponse { + _FakeApShowResponse_28( Object parent, Invocation parentInvocation, ) : super( @@ -351,9 +350,9 @@ class _FakeMisskeyNotesFavorites_28 extends _i1.SmartFake ); } -class _FakeMisskeyNotesPolls_29 extends _i1.SmartFake - implements _i6.MisskeyNotesPolls { - _FakeMisskeyNotesPolls_29( +class _FakeCommunityChannel_29 extends _i1.SmartFake + implements _i6.CommunityChannel { + _FakeCommunityChannel_29( Object parent, Invocation parentInvocation, ) : super( @@ -362,9 +361,8 @@ class _FakeMisskeyNotesPolls_29 extends _i1.SmartFake ); } -class _FakeMisskeyNotesThreadMuting_30 extends _i1.SmartFake - implements _i6.MisskeyNotesThreadMuting { - _FakeMisskeyNotesThreadMuting_30( +class _FakeClip_30 extends _i1.SmartFake implements _i6.Clip { + _FakeClip_30( Object parent, Invocation parentInvocation, ) : super( @@ -373,8 +371,9 @@ class _FakeMisskeyNotesThreadMuting_30 extends _i1.SmartFake ); } -class _FakeNote_31 extends _i1.SmartFake implements _i6.Note { - _FakeNote_31( +class _FakeMisskeyDriveFiles_31 extends _i1.SmartFake + implements _i6.MisskeyDriveFiles { + _FakeMisskeyDriveFiles_31( Object parent, Invocation parentInvocation, ) : super( @@ -383,9 +382,9 @@ class _FakeNote_31 extends _i1.SmartFake implements _i6.Note { ); } -class _FakeNotesStateResponse_32 extends _i1.SmartFake - implements _i6.NotesStateResponse { - _FakeNotesStateResponse_32( +class _FakeMisskeyDriveFolders_32 extends _i1.SmartFake + implements _i6.MisskeyDriveFolders { + _FakeMisskeyDriveFolders_32( Object parent, Invocation parentInvocation, ) : super( @@ -394,9 +393,8 @@ class _FakeNotesStateResponse_32 extends _i1.SmartFake ); } -class _FakeMisskeyUsersLists_33 extends _i1.SmartFake - implements _i6.MisskeyUsersLists { - _FakeMisskeyUsersLists_33( +class _FakeDriveFile_33 extends _i1.SmartFake implements _i6.DriveFile { + _FakeDriveFile_33( Object parent, Invocation parentInvocation, ) : super( @@ -405,9 +403,9 @@ class _FakeMisskeyUsersLists_33 extends _i1.SmartFake ); } -class _FakeUsersShowResponse_34 extends _i1.SmartFake - implements _i6.UsersShowResponse { - _FakeUsersShowResponse_34( +class _FakeFederationShowInstanceResponse_34 extends _i1.SmartFake + implements _i6.FederationShowInstanceResponse { + _FakeFederationShowInstanceResponse_34( Object parent, Invocation parentInvocation, ) : super( @@ -416,9 +414,9 @@ class _FakeUsersShowResponse_34 extends _i1.SmartFake ); } -class _FakeCommunityChannel_35 extends _i1.SmartFake - implements _i6.CommunityChannel { - _FakeCommunityChannel_35( +class _FakeMisskeyFollowingRequests_35 extends _i1.SmartFake + implements _i6.MisskeyFollowingRequests { + _FakeMisskeyFollowingRequests_35( Object parent, Invocation parentInvocation, ) : super( @@ -427,9 +425,8 @@ class _FakeCommunityChannel_35 extends _i1.SmartFake ); } -class _FakeMisskeyDriveFiles_36 extends _i1.SmartFake - implements _i6.MisskeyDriveFiles { - _FakeMisskeyDriveFiles_36( +class _FakeUser_36 extends _i1.SmartFake implements _i6.User { + _FakeUser_36( Object parent, Invocation parentInvocation, ) : super( @@ -438,9 +435,94 @@ class _FakeMisskeyDriveFiles_36 extends _i1.SmartFake ); } -class _FakeMisskeyDriveFolders_37 extends _i1.SmartFake - implements _i6.MisskeyDriveFolders { - _FakeMisskeyDriveFolders_37( +class _FakeHashtag_37 extends _i1.SmartFake implements _i6.Hashtag { + _FakeHashtag_37( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeIResponse_38 extends _i1.SmartFake implements _i6.IResponse { + _FakeIResponse_38( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeMisskeyNotesReactions_39 extends _i1.SmartFake + implements _i6.MisskeyNotesReactions { + _FakeMisskeyNotesReactions_39( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeMisskeyNotesFavorites_40 extends _i1.SmartFake + implements _i6.MisskeyNotesFavorites { + _FakeMisskeyNotesFavorites_40( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeMisskeyNotesPolls_41 extends _i1.SmartFake + implements _i6.MisskeyNotesPolls { + _FakeMisskeyNotesPolls_41( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeMisskeyNotesThreadMuting_42 extends _i1.SmartFake + implements _i6.MisskeyNotesThreadMuting { + _FakeMisskeyNotesThreadMuting_42( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeNote_43 extends _i1.SmartFake implements _i6.Note { + _FakeNote_43( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeNotesStateResponse_44 extends _i1.SmartFake + implements _i6.NotesStateResponse { + _FakeNotesStateResponse_44( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeRolesListResponse_45 extends _i1.SmartFake + implements _i6.RolesListResponse { + _FakeRolesListResponse_45( Object parent, Invocation parentInvocation, ) : super( @@ -449,8 +531,9 @@ class _FakeMisskeyDriveFolders_37 extends _i1.SmartFake ); } -class _FakeDriveFile_38 extends _i1.SmartFake implements _i6.DriveFile { - _FakeDriveFile_38( +class _FakeMisskeyUsersLists_46 extends _i1.SmartFake + implements _i6.MisskeyUsersLists { + _FakeMisskeyUsersLists_46( Object parent, Invocation parentInvocation, ) : super( @@ -459,8 +542,9 @@ class _FakeDriveFile_38 extends _i1.SmartFake implements _i6.DriveFile { ); } -class _FakeHashtag_39 extends _i1.SmartFake implements _i6.Hashtag { - _FakeHashtag_39( +class _FakeUsersShowResponse_47 extends _i1.SmartFake + implements _i6.UsersShowResponse { + _FakeUsersShowResponse_47( Object parent, Invocation parentInvocation, ) : super( @@ -469,8 +553,8 @@ class _FakeHashtag_39 extends _i1.SmartFake implements _i6.Hashtag { ); } -class _FakeBaseOptions_40 extends _i1.SmartFake implements _i9.BaseOptions { - _FakeBaseOptions_40( +class _FakeBaseOptions_48 extends _i1.SmartFake implements _i9.BaseOptions { + _FakeBaseOptions_48( Object parent, Invocation parentInvocation, ) : super( @@ -479,9 +563,29 @@ class _FakeBaseOptions_40 extends _i1.SmartFake implements _i9.BaseOptions { ); } -class _FakeHttpClientAdapter_41 extends _i1.SmartFake +class _FakeHttpClientAdapter_49 extends _i1.SmartFake implements _i10.HttpClientAdapter { - _FakeHttpClientAdapter_41( + _FakeHttpClientAdapter_49( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeTransformer_50 extends _i1.SmartFake implements _i11.Transformer { + _FakeTransformer_50( + Object parent, + Invocation parentInvocation, + ) : super( + parent, + parentInvocation, + ); +} + +class _FakeInterceptors_51 extends _i1.SmartFake implements _i12.Interceptors { + _FakeInterceptors_51( Object parent, Invocation parentInvocation, ) : super( @@ -490,8 +594,8 @@ class _FakeHttpClientAdapter_41 extends _i1.SmartFake ); } -class _FakeTransformer_42 extends _i1.SmartFake implements _i11.Transformer { - _FakeTransformer_42( +class _FakeResponse_52 extends _i1.SmartFake implements _i13.Response { + _FakeResponse_52( Object parent, Invocation parentInvocation, ) : super( @@ -500,8 +604,8 @@ class _FakeTransformer_42 extends _i1.SmartFake implements _i11.Transformer { ); } -class _FakeInterceptors_43 extends _i1.SmartFake implements _i12.Interceptors { - _FakeInterceptors_43( +class _FakeDuration_53 extends _i1.SmartFake implements Duration { + _FakeDuration_53( Object parent, Invocation parentInvocation, ) : super( @@ -510,8 +614,9 @@ class _FakeInterceptors_43 extends _i1.SmartFake implements _i12.Interceptors { ); } -class _FakeResponse_44 extends _i1.SmartFake implements _i13.Response { - _FakeResponse_44( +class _FakeHttpClientRequest_54 extends _i1.SmartFake + implements _i14.HttpClientRequest { + _FakeHttpClientRequest_54( Object parent, Invocation parentInvocation, ) : super( @@ -524,13 +629,13 @@ class _FakeResponse_44 extends _i1.SmartFake implements _i13.Response { /// /// See the documentation for Mockito's code generation for more information. class MockTabSettingsRepository extends _i1.Mock - implements _i14.TabSettingsRepository { + implements _i15.TabSettingsRepository { @override - Iterable<_i15.TabSetting> get tabSettings => (super.noSuchMethod( + Iterable<_i16.TabSetting> get tabSettings => (super.noSuchMethod( Invocation.getter(#tabSettings), - returnValue: <_i15.TabSetting>[], - returnValueForMissingStub: <_i15.TabSetting>[], - ) as Iterable<_i15.TabSetting>); + returnValue: <_i16.TabSetting>[], + returnValueForMissingStub: <_i16.TabSetting>[], + ) as Iterable<_i16.TabSetting>); @override bool get hasListeners => (super.noSuchMethod( Invocation.getter(#hasListeners), @@ -538,17 +643,17 @@ class MockTabSettingsRepository extends _i1.Mock returnValueForMissingStub: false, ) as bool); @override - _i16.Future load() => (super.noSuchMethod( + _i17.Future load() => (super.noSuchMethod( Invocation.method( #load, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override void updateAccount( - _i17.Account? account, + _i18.Account? account, _i6.IResponse? response, ) => super.noSuchMethod( @@ -562,26 +667,26 @@ class MockTabSettingsRepository extends _i1.Mock returnValueForMissingStub: null, ); @override - _i16.Future save(List<_i15.TabSetting>? tabSettings) => + _i17.Future save(List<_i16.TabSetting>? tabSettings) => (super.noSuchMethod( Invocation.method( #save, [tabSettings], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future removeAccount(_i17.Account? account) => (super.noSuchMethod( + _i17.Future removeAccount(_i18.Account? account) => (super.noSuchMethod( Invocation.method( #removeAccount, [account], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - void addListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void addListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #addListener, [listener], @@ -589,7 +694,7 @@ class MockTabSettingsRepository extends _i1.Mock returnValueForMissingStub: null, ); @override - void removeListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void removeListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #removeListener, [listener], @@ -618,7 +723,7 @@ class MockTabSettingsRepository extends _i1.Mock /// /// See the documentation for Mockito's code generation for more information. class MockAccountSettingsRepository extends _i1.Mock - implements _i19.AccountSettingsRepository { + implements _i20.AccountSettingsRepository { @override Iterable<_i2.AccountSettings> get accountSettings => (super.noSuchMethod( Invocation.getter(#accountSettings), @@ -632,34 +737,34 @@ class MockAccountSettingsRepository extends _i1.Mock returnValueForMissingStub: false, ) as bool); @override - _i16.Future load() => (super.noSuchMethod( + _i17.Future load() => (super.noSuchMethod( Invocation.method( #load, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future save(_i2.AccountSettings? settings) => (super.noSuchMethod( + _i17.Future save(_i2.AccountSettings? settings) => (super.noSuchMethod( Invocation.method( #save, [settings], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future removeAccount(_i17.Account? account) => (super.noSuchMethod( + _i17.Future removeAccount(_i18.Account? account) => (super.noSuchMethod( Invocation.method( #removeAccount, [account], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i2.AccountSettings fromAccount(_i17.Account? account) => (super.noSuchMethod( + _i2.AccountSettings fromAccount(_i18.Account? account) => (super.noSuchMethod( Invocation.method( #fromAccount, [account], @@ -680,7 +785,7 @@ class MockAccountSettingsRepository extends _i1.Mock ), ) as _i2.AccountSettings); @override - void addListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void addListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #addListener, [listener], @@ -688,7 +793,7 @@ class MockAccountSettingsRepository extends _i1.Mock returnValueForMissingStub: null, ); @override - void removeListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void removeListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #removeListener, [listener], @@ -716,9 +821,9 @@ class MockAccountSettingsRepository extends _i1.Mock /// A class which mocks [EmojiRepository]. /// /// See the documentation for Mockito's code generation for more information. -class MockEmojiRepository extends _i1.Mock implements _i20.EmojiRepository { +class MockEmojiRepository extends _i1.Mock implements _i21.EmojiRepository { @override - set emoji(List<_i20.EmojiRepositoryData>? _emoji) => super.noSuchMethod( + set emoji(List<_i21.EmojiRepositoryData>? _emoji) => super.noSuchMethod( Invocation.setter( #emoji, _emoji, @@ -726,34 +831,34 @@ class MockEmojiRepository extends _i1.Mock implements _i20.EmojiRepository { returnValueForMissingStub: null, ); @override - _i16.Future loadFromSourceIfNeed() => (super.noSuchMethod( + _i17.Future loadFromSourceIfNeed() => (super.noSuchMethod( Invocation.method( #loadFromSourceIfNeed, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future loadFromSource() => (super.noSuchMethod( + _i17.Future loadFromSource() => (super.noSuchMethod( Invocation.method( #loadFromSource, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future loadFromLocalCache() => (super.noSuchMethod( + _i17.Future loadFromLocalCache() => (super.noSuchMethod( Invocation.method( #loadFromLocalCache, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> searchEmojis( + _i17.Future> searchEmojis( String? name, { int? limit = 30, }) => @@ -763,30 +868,30 @@ class MockEmojiRepository extends _i1.Mock implements _i20.EmojiRepository { [name], {#limit: limit}, ), - returnValue: _i16.Future>.value( - <_i21.MisskeyEmojiData>[]), + returnValue: _i17.Future>.value( + <_i22.MisskeyEmojiData>[]), returnValueForMissingStub: - _i16.Future>.value( - <_i21.MisskeyEmojiData>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i22.MisskeyEmojiData>[]), + ) as _i17.Future>); @override - List<_i21.MisskeyEmojiData> defaultEmojis({int? limit}) => + List<_i22.MisskeyEmojiData> defaultEmojis({int? limit}) => (super.noSuchMethod( Invocation.method( #defaultEmojis, [], {#limit: limit}, ), - returnValue: <_i21.MisskeyEmojiData>[], - returnValueForMissingStub: <_i21.MisskeyEmojiData>[], - ) as List<_i21.MisskeyEmojiData>); + returnValue: <_i22.MisskeyEmojiData>[], + returnValueForMissingStub: <_i22.MisskeyEmojiData>[], + ) as List<_i22.MisskeyEmojiData>); } /// A class which mocks [GeneralSettingsRepository]. /// /// See the documentation for Mockito's code generation for more information. class MockGeneralSettingsRepository extends _i1.Mock - implements _i22.GeneralSettingsRepository { + implements _i23.GeneralSettingsRepository { @override _i3.GeneralSettings get settings => (super.noSuchMethod( Invocation.getter(#settings), @@ -806,26 +911,26 @@ class MockGeneralSettingsRepository extends _i1.Mock returnValueForMissingStub: false, ) as bool); @override - _i16.Future load() => (super.noSuchMethod( + _i17.Future load() => (super.noSuchMethod( Invocation.method( #load, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future update(_i3.GeneralSettings? settings) => + _i17.Future update(_i3.GeneralSettings? settings) => (super.noSuchMethod( Invocation.method( #update, [settings], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - void addListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void addListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #addListener, [listener], @@ -833,7 +938,7 @@ class MockGeneralSettingsRepository extends _i1.Mock returnValueForMissingStub: null, ); @override - void removeListener(_i18.VoidCallback? listener) => super.noSuchMethod( + void removeListener(_i19.VoidCallback? listener) => super.noSuchMethod( Invocation.method( #removeListener, [listener], @@ -1210,36 +1315,36 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { returnValueForMissingStub: null, ); @override - _i16.Future> announcements( + _i17.Future> announcements( _i6.AnnouncementsRequest? request) => (super.noSuchMethod( Invocation.method( #announcements, [request], ), - returnValue: _i16.Future>.value( + returnValue: _i17.Future>.value( <_i6.AnnouncementsResponse>[]), returnValueForMissingStub: - _i16.Future>.value( + _i17.Future>.value( <_i6.AnnouncementsResponse>[]), - ) as _i16.Future>); + ) as _i17.Future>); @override - _i16.Future> endpoints() => (super.noSuchMethod( + _i17.Future> endpoints() => (super.noSuchMethod( Invocation.method( #endpoints, [], ), - returnValue: _i16.Future>.value([]), - returnValueForMissingStub: _i16.Future>.value([]), - ) as _i16.Future>); + returnValue: _i17.Future>.value([]), + returnValueForMissingStub: _i17.Future>.value([]), + ) as _i17.Future>); @override - _i16.Future<_i6.EmojisResponse> emojis() => (super.noSuchMethod( + _i17.Future<_i6.EmojisResponse> emojis() => (super.noSuchMethod( Invocation.method( #emojis, [], ), returnValue: - _i16.Future<_i6.EmojisResponse>.value(_FakeEmojisResponse_19( + _i17.Future<_i6.EmojisResponse>.value(_FakeEmojisResponse_19( this, Invocation.method( #emojis, @@ -1247,22 +1352,22 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i6.EmojisResponse>.value(_FakeEmojisResponse_19( + _i17.Future<_i6.EmojisResponse>.value(_FakeEmojisResponse_19( this, Invocation.method( #emojis, [], ), )), - ) as _i16.Future<_i6.EmojisResponse>); + ) as _i17.Future<_i6.EmojisResponse>); @override - _i16.Future<_i6.EmojiResponse> emoji(_i6.EmojiRequest? request) => + _i17.Future<_i6.EmojiResponse> emoji(_i6.EmojiRequest? request) => (super.noSuchMethod( Invocation.method( #emoji, [request], ), - returnValue: _i16.Future<_i6.EmojiResponse>.value(_FakeEmojiResponse_20( + returnValue: _i17.Future<_i6.EmojiResponse>.value(_FakeEmojiResponse_20( this, Invocation.method( #emoji, @@ -1270,21 +1375,21 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i6.EmojiResponse>.value(_FakeEmojiResponse_20( + _i17.Future<_i6.EmojiResponse>.value(_FakeEmojiResponse_20( this, Invocation.method( #emoji, [request], ), )), - ) as _i16.Future<_i6.EmojiResponse>); + ) as _i17.Future<_i6.EmojiResponse>); @override - _i16.Future<_i6.MetaResponse> meta() => (super.noSuchMethod( + _i17.Future<_i6.MetaResponse> meta() => (super.noSuchMethod( Invocation.method( #meta, [], ), - returnValue: _i16.Future<_i6.MetaResponse>.value(_FakeMetaResponse_21( + returnValue: _i17.Future<_i6.MetaResponse>.value(_FakeMetaResponse_21( this, Invocation.method( #meta, @@ -1292,21 +1397,21 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i6.MetaResponse>.value(_FakeMetaResponse_21( + _i17.Future<_i6.MetaResponse>.value(_FakeMetaResponse_21( this, Invocation.method( #meta, [], ), )), - ) as _i16.Future<_i6.MetaResponse>); + ) as _i17.Future<_i6.MetaResponse>); @override - _i16.Future<_i7.StatsResponse> stats() => (super.noSuchMethod( + _i17.Future<_i7.StatsResponse> stats() => (super.noSuchMethod( Invocation.method( #stats, [], ), - returnValue: _i16.Future<_i7.StatsResponse>.value(_FakeStatsResponse_22( + returnValue: _i17.Future<_i7.StatsResponse>.value(_FakeStatsResponse_22( this, Invocation.method( #stats, @@ -1314,21 +1419,21 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i7.StatsResponse>.value(_FakeStatsResponse_22( + _i17.Future<_i7.StatsResponse>.value(_FakeStatsResponse_22( this, Invocation.method( #stats, [], ), )), - ) as _i16.Future<_i7.StatsResponse>); + ) as _i17.Future<_i7.StatsResponse>); @override - _i16.Future<_i8.PingResponse> ping() => (super.noSuchMethod( + _i17.Future<_i8.PingResponse> ping() => (super.noSuchMethod( Invocation.method( #ping, [], ), - returnValue: _i16.Future<_i8.PingResponse>.value(_FakePingResponse_23( + returnValue: _i17.Future<_i8.PingResponse>.value(_FakePingResponse_23( this, Invocation.method( #ping, @@ -1336,21 +1441,21 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i8.PingResponse>.value(_FakePingResponse_23( + _i17.Future<_i8.PingResponse>.value(_FakePingResponse_23( this, Invocation.method( #ping, [], ), )), - ) as _i16.Future<_i8.PingResponse>); + ) as _i17.Future<_i8.PingResponse>); @override - _i16.Future<_i6.ServerInfoResponse> serverInfo() => (super.noSuchMethod( + _i17.Future<_i6.ServerInfoResponse> serverInfo() => (super.noSuchMethod( Invocation.method( #serverInfo, [], ), - returnValue: _i16.Future<_i6.ServerInfoResponse>.value( + returnValue: _i17.Future<_i6.ServerInfoResponse>.value( _FakeServerInfoResponse_24( this, Invocation.method( @@ -1358,7 +1463,7 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { [], ), )), - returnValueForMissingStub: _i16.Future<_i6.ServerInfoResponse>.value( + returnValueForMissingStub: _i17.Future<_i6.ServerInfoResponse>.value( _FakeServerInfoResponse_24( this, Invocation.method( @@ -1366,15 +1471,15 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { [], ), )), - ) as _i16.Future<_i6.ServerInfoResponse>); + ) as _i17.Future<_i6.ServerInfoResponse>); @override - _i16.Future<_i6.GetOnlineUsersCountResponse> getOnlineUsersCount() => + _i17.Future<_i6.GetOnlineUsersCountResponse> getOnlineUsersCount() => (super.noSuchMethod( Invocation.method( #getOnlineUsersCount, [], ), - returnValue: _i16.Future<_i6.GetOnlineUsersCountResponse>.value( + returnValue: _i17.Future<_i6.GetOnlineUsersCountResponse>.value( _FakeGetOnlineUsersCountResponse_25( this, Invocation.method( @@ -1383,7 +1488,7 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), )), returnValueForMissingStub: - _i16.Future<_i6.GetOnlineUsersCountResponse>.value( + _i17.Future<_i6.GetOnlineUsersCountResponse>.value( _FakeGetOnlineUsersCountResponse_25( this, Invocation.method( @@ -1391,37 +1496,37 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { [], ), )), - ) as _i16.Future<_i6.GetOnlineUsersCountResponse>); + ) as _i17.Future<_i6.GetOnlineUsersCountResponse>); @override - _i16.Future> pinnedUsers() => (super.noSuchMethod( + _i17.Future> pinnedUsers() => (super.noSuchMethod( Invocation.method( #pinnedUsers, [], ), - returnValue: _i16.Future>.value(<_i6.User>[]), + returnValue: _i17.Future>.value(<_i6.User>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.User>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); @override _i6.SocketController homeTimelineStream({ - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1472,24 +1577,24 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController localTimelineStream({ - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1540,24 +1645,24 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController globalTimelineStream({ - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1608,24 +1713,24 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController hybridTimelineStream({ - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1677,20 +1782,20 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { @override _i6.SocketController roleTimelineStream({ required String? roleId, - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, @@ -1742,24 +1847,24 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { @override _i6.SocketController channelStream({ required String? channelId, - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1814,23 +1919,23 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { @override _i6.SocketController userListStream({ required String? listId, - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function(_i6.User)? onUserAdded, - _i16.FutureOr Function(_i6.User)? onUserRemoved, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function(_i6.User)? onUserAdded, + _i17.FutureOr Function(_i6.User)? onUserRemoved, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, - _i16.FutureOr Function(DateTime)? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function(DateTime)? onDeleted, + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, @@ -1891,24 +1996,24 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { @override _i6.SocketController antennaStream({ required String? antennaId, - _i16.FutureOr Function(_i6.Note)? onNoteReceived, - _i16.FutureOr Function( + _i17.FutureOr Function(_i6.Note)? onNoteReceived, + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onReacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineReacted, )? onUnreacted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, DateTime, )? onDeleted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.TimelineVoted, )? onVoted, - _i16.FutureOr Function( + _i17.FutureOr Function( String, _i6.NoteEdited, )? onUpdated, @@ -1962,8 +2067,8 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController serverStatsLogStream( - _i16.FutureOr Function(List<_i6.StatsLogResponse>)? onLogReceived, - _i16.FutureOr Function(_i6.StatsLogResponse)? onEventReceived, + _i17.FutureOr Function(List<_i6.StatsLogResponse>)? onLogReceived, + _i17.FutureOr Function(_i6.StatsLogResponse)? onEventReceived, ) => (super.noSuchMethod( Invocation.method( @@ -1996,9 +2101,9 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController queueStatsLogStream( - _i16.FutureOr Function(List<_i6.QueueStatsLogResponse>)? + _i17.FutureOr Function(List<_i6.QueueStatsLogResponse>)? onLogReceived, - _i16.FutureOr Function(_i6.QueueStatsLogResponse)? onEventReceived, + _i17.FutureOr Function(_i6.QueueStatsLogResponse)? onEventReceived, ) => (super.noSuchMethod( Invocation.method( @@ -2031,28 +2136,28 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ) as _i6.SocketController); @override _i6.SocketController mainStream({ - _i16.FutureOr Function(_i6.Emoji)? onEmojiAdded, - _i16.FutureOr Function(Iterable<_i6.Emoji>)? onEmojiUpdated, - _i16.FutureOr Function(Iterable<_i6.Emoji>)? onEmojiDeleted, - _i16.FutureOr Function(_i6.AnnouncementsResponse)? + _i17.FutureOr Function(_i6.Emoji)? onEmojiAdded, + _i17.FutureOr Function(Iterable<_i6.Emoji>)? onEmojiUpdated, + _i17.FutureOr Function(Iterable<_i6.Emoji>)? onEmojiDeleted, + _i17.FutureOr Function(_i6.AnnouncementsResponse)? onAnnouncementCreated, - _i16.FutureOr Function(_i6.INotificationsResponse)? onNotification, - _i16.FutureOr Function(_i6.Note)? onMention, - _i16.FutureOr Function(_i6.Note)? onReply, - _i16.FutureOr Function(_i6.Note)? onRenote, - _i16.FutureOr Function(_i6.User)? onFollow, - _i16.FutureOr Function(_i6.User)? onFollowed, - _i16.FutureOr Function(_i6.User)? onUnfollow, - _i16.FutureOr Function(_i6.User)? onMeUpdated, - _i16.FutureOr Function()? onReadAllNotifications, - _i16.FutureOr Function(_i6.INotificationsResponse)? + _i17.FutureOr Function(_i6.INotificationsResponse)? onNotification, + _i17.FutureOr Function(_i6.Note)? onMention, + _i17.FutureOr Function(_i6.Note)? onReply, + _i17.FutureOr Function(_i6.Note)? onRenote, + _i17.FutureOr Function(_i6.User)? onFollow, + _i17.FutureOr Function(_i6.User)? onFollowed, + _i17.FutureOr Function(_i6.User)? onUnfollow, + _i17.FutureOr Function(_i6.User)? onMeUpdated, + _i17.FutureOr Function()? onReadAllNotifications, + _i17.FutureOr Function(_i6.INotificationsResponse)? onUnreadNotification, - _i16.FutureOr Function(String)? onUnreadMention, - _i16.FutureOr Function()? onReadAllUnreadMentions, - _i16.FutureOr Function(String)? onUnreadSpecifiedNote, - _i16.FutureOr Function()? onReadAllUnreadSpecifiedNotes, - _i16.FutureOr Function(_i6.User)? onReceiveFollowRequest, - _i16.FutureOr Function()? onReadAllAnnouncements, + _i17.FutureOr Function(String)? onUnreadMention, + _i17.FutureOr Function()? onReadAllUnreadMentions, + _i17.FutureOr Function(String)? onUnreadSpecifiedNote, + _i17.FutureOr Function()? onReadAllUnreadSpecifiedNotes, + _i17.FutureOr Function(_i6.User)? onReceiveFollowRequest, + _i17.FutureOr Function()? onReadAllAnnouncements, }) => (super.noSuchMethod( Invocation.method( @@ -2141,746 +2246,501 @@ class MockMisskey extends _i1.Mock implements _i6.Misskey { ), ) as _i6.SocketController); @override - _i16.Future startStreaming() => (super.noSuchMethod( + _i17.Future startStreaming() => (super.noSuchMethod( Invocation.method( #startStreaming, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); } -/// A class which mocks [MisskeyNotes]. +/// A class which mocks [MisskeyAntenna]. /// /// See the documentation for Mockito's code generation for more information. -class MockMisskeyNotes extends _i1.Mock implements _i6.MisskeyNotes { - @override - _i6.MisskeyNotesReactions get reactions => (super.noSuchMethod( - Invocation.getter(#reactions), - returnValue: _FakeMisskeyNotesReactions_27( - this, - Invocation.getter(#reactions), - ), - returnValueForMissingStub: _FakeMisskeyNotesReactions_27( - this, - Invocation.getter(#reactions), - ), - ) as _i6.MisskeyNotesReactions); - @override - _i6.MisskeyNotesFavorites get favorites => (super.noSuchMethod( - Invocation.getter(#favorites), - returnValue: _FakeMisskeyNotesFavorites_28( - this, - Invocation.getter(#favorites), - ), - returnValueForMissingStub: _FakeMisskeyNotesFavorites_28( - this, - Invocation.getter(#favorites), - ), - ) as _i6.MisskeyNotesFavorites); - @override - _i6.MisskeyNotesPolls get polls => (super.noSuchMethod( - Invocation.getter(#polls), - returnValue: _FakeMisskeyNotesPolls_29( - this, - Invocation.getter(#polls), - ), - returnValueForMissingStub: _FakeMisskeyNotesPolls_29( - this, - Invocation.getter(#polls), - ), - ) as _i6.MisskeyNotesPolls); - @override - _i6.MisskeyNotesThreadMuting get threadMuting => (super.noSuchMethod( - Invocation.getter(#threadMuting), - returnValue: _FakeMisskeyNotesThreadMuting_30( - this, - Invocation.getter(#threadMuting), - ), - returnValueForMissingStub: _FakeMisskeyNotesThreadMuting_30( - this, - Invocation.getter(#threadMuting), - ), - ) as _i6.MisskeyNotesThreadMuting); +class MockMisskeyAntenna extends _i1.Mock implements _i6.MisskeyAntenna { @override - _i16.Future create(_i6.NotesCreateRequest? request) => + _i17.Future<_i6.Antenna> create(_i6.AntennasCreateRequest? request) => (super.noSuchMethod( Invocation.method( #create, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future<_i6.Antenna>.value(_FakeAntenna_27( + this, + Invocation.method( + #create, + [request], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.Antenna>.value(_FakeAntenna_27( + this, + Invocation.method( + #create, + [request], + ), + )), + ) as _i17.Future<_i6.Antenna>); @override - _i16.Future update(_i6.NotesUpdateRequest? request) => + _i17.Future delete(_i6.AntennasDeleteRequest? request) => (super.noSuchMethod( Invocation.method( - #update, + #delete, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future delete(_i6.NotesDeleteRequest? request) => - (super.noSuchMethod( + _i17.Future> list() => (super.noSuchMethod( Invocation.method( - #delete, - [request], + #list, + [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future>.value(<_i6.Antenna>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Antenna>[]), + ) as _i17.Future>); @override - _i16.Future> notes(_i6.NotesRequest? request) => + _i17.Future> notes(_i6.AntennasNotesRequest? request) => (super.noSuchMethod( Invocation.method( #notes, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value(<_i6.Note>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); @override - _i16.Future<_i6.Note> show(_i6.NotesShowRequest? request) => + _i17.Future<_i6.Antenna> show(_i6.AntennasShowRequest? request) => (super.noSuchMethod( Invocation.method( #show, [request], ), - returnValue: _i16.Future<_i6.Note>.value(_FakeNote_31( + returnValue: _i17.Future<_i6.Antenna>.value(_FakeAntenna_27( this, Invocation.method( #show, [request], ), )), - returnValueForMissingStub: _i16.Future<_i6.Note>.value(_FakeNote_31( + returnValueForMissingStub: + _i17.Future<_i6.Antenna>.value(_FakeAntenna_27( this, Invocation.method( #show, [request], ), )), - ) as _i16.Future<_i6.Note>); + ) as _i17.Future<_i6.Antenna>); @override - _i16.Future> homeTimeline( - _i6.NotesTimelineRequest? request) => + _i17.Future update(_i6.AntennasUpdateRequest? request) => (super.noSuchMethod( Invocation.method( - #homeTimeline, + #update, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyAp]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyAp extends _i1.Mock implements _i6.MisskeyAp { @override - _i16.Future> localTimeline( - _i6.NotesLocalTimelineRequest? request) => + _i17.Future<_i6.ApShowResponse> show(_i6.ApShowRequest? request) => (super.noSuchMethod( Invocation.method( - #localTimeline, + #show, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: + _i17.Future<_i6.ApShowResponse>.value(_FakeApShowResponse_28( + this, + Invocation.method( + #show, + [request], + ), + )), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future<_i6.ApShowResponse>.value(_FakeApShowResponse_28( + this, + Invocation.method( + #show, + [request], + ), + )), + ) as _i17.Future<_i6.ApShowResponse>); +} + +/// A class which mocks [MisskeyBlocking]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyBlocking extends _i1.Mock implements _i6.MisskeyBlocking { @override - _i16.Future> hybridTimeline( - _i6.NotesHybridTimelineRequest? request) => + _i17.Future create(_i6.BlockCreateRequest? request) => (super.noSuchMethod( Invocation.method( - #hybridTimeline, + #create, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> globalTimeline( - _i6.NotesGlobalTimelineRequest? request) => + _i17.Future delete(_i6.BlockDeleteRequest? request) => (super.noSuchMethod( Invocation.method( - #globalTimeline, + #delete, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyChannels]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyChannels extends _i1.Mock implements _i6.MisskeyChannels { @override - _i16.Future> userListTimeline( - _i6.UserListTimelineRequest? request) => + _i17.Future> timeline( + _i6.ChannelsTimelineRequest? request) => (super.noSuchMethod( Invocation.method( - #userListTimeline, + #timeline, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value(<_i6.Note>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); @override - _i16.Future<_i6.NotesStateResponse> state(_i6.NotesStateRequest? request) => + _i17.Future<_i6.CommunityChannel> show(_i6.ChannelsShowRequest? request) => (super.noSuchMethod( Invocation.method( - #state, + #show, [request], ), - returnValue: _i16.Future<_i6.NotesStateResponse>.value( - _FakeNotesStateResponse_32( + returnValue: + _i17.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_29( this, Invocation.method( - #state, + #show, [request], ), )), - returnValueForMissingStub: _i16.Future<_i6.NotesStateResponse>.value( - _FakeNotesStateResponse_32( + returnValueForMissingStub: + _i17.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_29( this, Invocation.method( - #state, + #show, [request], ), )), - ) as _i16.Future<_i6.NotesStateResponse>); + ) as _i17.Future<_i6.CommunityChannel>); @override - _i16.Future> search(_i6.NotesSearchRequest? request) => + _i17.Future> followed( + _i6.ChannelsFollowedRequest? request) => (super.noSuchMethod( Invocation.method( - #search, + #followed, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value( + <_i6.CommunityChannel>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i6.CommunityChannel>[]), + ) as _i17.Future>); @override - _i16.Future> searchByTag( - _i6.NotesSearchByTagRequest? request) => + _i17.Future> myFavorite( + _i6.ChannelsMyFavoriteRequest? request) => (super.noSuchMethod( Invocation.method( - #searchByTag, + #myFavorite, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value( + <_i6.CommunityChannel>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i6.CommunityChannel>[]), + ) as _i17.Future>); @override - _i16.Future> renotes(_i6.NotesRenoteRequest? request) => - (super.noSuchMethod( + _i17.Future> featured() => (super.noSuchMethod( Invocation.method( - #renotes, - [request], + #featured, + [], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value( + <_i6.CommunityChannel>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i6.CommunityChannel>[]), + ) as _i17.Future>); @override - _i16.Future> replies(_i6.NotesRepliesRequest? request) => + _i17.Future> owned( + _i6.ChannelsOwnedRequest? request) => (super.noSuchMethod( Invocation.method( - #replies, + #owned, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value( + <_i6.CommunityChannel>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i6.CommunityChannel>[]), + ) as _i17.Future>); @override - _i16.Future> children(_i6.NotesChildrenRequest? request) => + _i17.Future> search( + _i6.ChannelsSearchRequest? request) => (super.noSuchMethod( Invocation.method( - #children, + #search, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), + returnValue: _i17.Future>.value( + <_i6.CommunityChannel>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + _i17.Future>.value( + <_i6.CommunityChannel>[]), + ) as _i17.Future>); @override - _i16.Future> conversation( - _i6.NotesConversationRequest? request) => + _i17.Future<_i6.CommunityChannel> create( + _i6.ChannelsCreateRequest? request) => (super.noSuchMethod( Invocation.method( - #conversation, - [request], - ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); - @override - _i16.Future> featured(_i6.NotesFeaturedRequest? request) => - (super.noSuchMethod( - Invocation.method( - #featured, - [request], - ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); - @override - _i16.Future> mentions(_i6.NotesMentionsRequest? request) => - (super.noSuchMethod( - Invocation.method( - #mentions, - [request], - ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); - @override - _i16.Future> clips(_i6.NotesClipsRequest? request) => - (super.noSuchMethod( - Invocation.method( - #clips, - [request], - ), - returnValue: _i16.Future>.value(<_i6.Clip>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Clip>[]), - ) as _i16.Future>); - @override - _i16.Future unrenote(_i6.NotesUnrenoteRequest? request) => - (super.noSuchMethod( - Invocation.method( - #unrenote, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); -} - -/// A class which mocks [MisskeyNotesFavorites]. -/// -/// See the documentation for Mockito's code generation for more information. -class MockMisskeyNotesFavorites extends _i1.Mock - implements _i6.MisskeyNotesFavorites { - @override - _i16.Future create(_i6.NotesFavoritesCreateRequest? request) => - (super.noSuchMethod( - Invocation.method( - #create, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); - @override - _i16.Future delete(_i6.NotesFavoritesDeleteRequest? request) => - (super.noSuchMethod( - Invocation.method( - #delete, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); -} - -/// A class which mocks [MisskeyUsers]. -/// -/// See the documentation for Mockito's code generation for more information. -class MockMisskeyUsers extends _i1.Mock implements _i6.MisskeyUsers { - @override - _i6.MisskeyUsersLists get list => (super.noSuchMethod( - Invocation.getter(#list), - returnValue: _FakeMisskeyUsersLists_33( - this, - Invocation.getter(#list), - ), - returnValueForMissingStub: _FakeMisskeyUsersLists_33( - this, - Invocation.getter(#list), - ), - ) as _i6.MisskeyUsersLists); - @override - _i16.Future<_i6.UsersShowResponse> show(_i6.UsersShowRequest? request) => - (super.noSuchMethod( - Invocation.method( - #show, - [request], - ), - returnValue: - _i16.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_34( - this, - Invocation.method( - #show, - [request], - ), - )), - returnValueForMissingStub: - _i16.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_34( - this, - Invocation.method( - #show, - [request], - ), - )), - ) as _i16.Future<_i6.UsersShowResponse>); - @override - _i16.Future> showByIds( - _i6.UsersShowByIdsRequest? request) => - (super.noSuchMethod( - Invocation.method( - #showByIds, - [request], - ), - returnValue: _i16.Future>.value( - <_i6.UsersShowResponse>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.UsersShowResponse>[]), - ) as _i16.Future>); - @override - _i16.Future<_i6.UsersShowResponse> showByName( - _i6.UsersShowByUserNameRequest? request) => - (super.noSuchMethod( - Invocation.method( - #showByName, + #create, [request], ), returnValue: - _i16.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_34( + _i17.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_29( this, Invocation.method( - #showByName, + #create, [request], ), )), returnValueForMissingStub: - _i16.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_34( + _i17.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_29( this, Invocation.method( - #showByName, + #create, [request], ), )), - ) as _i16.Future<_i6.UsersShowResponse>); - @override - _i16.Future> notes(_i6.UsersNotesRequest? request) => - (super.noSuchMethod( - Invocation.method( - #notes, - [request], - ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + ) as _i17.Future<_i6.CommunityChannel>); @override - _i16.Future> clips(_i6.UsersClipsRequest? request) => + _i17.Future update(_i6.ChannelsUpdateRequest? request) => (super.noSuchMethod( Invocation.method( - #clips, + #update, [request], ), - returnValue: _i16.Future>.value(<_i6.Clip>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Clip>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> followers( - _i6.UsersFollowersRequest? request) => + _i17.Future favorite(_i6.ChannelsFavoriteRequest? request) => (super.noSuchMethod( Invocation.method( - #followers, + #favorite, [request], ), - returnValue: - _i16.Future>.value(<_i6.Following>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Following>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> following( - _i6.UsersFollowingRequest? request) => + _i17.Future unfavorite(_i6.ChannelsUnfavoriteRequest? request) => (super.noSuchMethod( Invocation.method( - #following, + #unfavorite, [request], ), - returnValue: - _i16.Future>.value(<_i6.Following>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Following>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future reportAbuse(_i6.UsersReportAbuseRequest? request) => + _i17.Future follow(_i6.ChannelsFollowRequest? request) => (super.noSuchMethod( Invocation.method( - #reportAbuse, + #follow, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> reactions( - _i6.UsersReactionsRequest? request) => + _i17.Future unfollow(_i6.ChannelsUnfollowRequest? request) => (super.noSuchMethod( Invocation.method( - #reactions, + #unfollow, [request], ), - returnValue: _i16.Future>.value( - <_i6.UsersReactionsResponse>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.UsersReactionsResponse>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyClips]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyClips extends _i1.Mock implements _i6.MisskeyClips { @override - _i16.Future> search(_i6.UsersSearchRequest? request) => - (super.noSuchMethod( + _i17.Future> list() => (super.noSuchMethod( Invocation.method( - #search, - [request], + #list, + [], ), - returnValue: _i16.Future>.value(<_i6.User>[]), + returnValue: _i17.Future>.value(<_i6.Clip>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.User>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.Clip>[]), + ) as _i17.Future>); @override - _i16.Future> recommendation( - _i6.UsersRecommendationRequest? request) => - (super.noSuchMethod( + _i17.Future> myFavorites() => (super.noSuchMethod( Invocation.method( - #recommendation, - [request], + #myFavorites, + [], ), - returnValue: _i16.Future>.value(<_i6.User>[]), + returnValue: _i17.Future>.value(<_i6.Clip>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.User>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.Clip>[]), + ) as _i17.Future>); @override - _i16.Future> users(_i6.UsersUsersRequest? request) => + _i17.Future> notes(_i6.ClipsNotesRequest? request) => (super.noSuchMethod( Invocation.method( - #users, + #notes, [request], ), - returnValue: _i16.Future>.value(<_i6.User>[]), + returnValue: _i17.Future>.value(<_i6.Note>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.User>[]), - ) as _i16.Future>); - @override - _i16.Future updateMemo(_i6.UsersUpdateMemoRequest? request) => - (super.noSuchMethod( - Invocation.method( - #updateMemo, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); @override - _i16.Future> flashs(_i6.UsersFlashsRequest? request) => + _i17.Future addNote(_i6.ClipsAddNoteRequest? request) => (super.noSuchMethod( Invocation.method( - #flashs, + #addNote, [request], ), - returnValue: _i16.Future>.value(<_i6.Flash>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Flash>[]), - ) as _i16.Future>); -} - -/// A class which mocks [MisskeyChannels]. -/// -/// See the documentation for Mockito's code generation for more information. -class MockMisskeyChannels extends _i1.Mock implements _i6.MisskeyChannels { + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> timeline( - _i6.ChannelsTimelineRequest? request) => + _i17.Future removeNote(_i6.ClipsRemoveNoteRequest? request) => (super.noSuchMethod( Invocation.method( - #timeline, + #removeNote, [request], ), - returnValue: _i16.Future>.value(<_i6.Note>[]), - returnValueForMissingStub: - _i16.Future>.value(<_i6.Note>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future<_i6.CommunityChannel> show(_i6.ChannelsShowRequest? request) => + _i17.Future<_i6.Clip> create(_i6.ClipsCreateRequest? request) => (super.noSuchMethod( Invocation.method( - #show, + #create, [request], ), - returnValue: - _i16.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_35( + returnValue: _i17.Future<_i6.Clip>.value(_FakeClip_30( this, Invocation.method( - #show, + #create, [request], ), )), - returnValueForMissingStub: - _i16.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_35( + returnValueForMissingStub: _i17.Future<_i6.Clip>.value(_FakeClip_30( this, Invocation.method( - #show, + #create, [request], ), )), - ) as _i16.Future<_i6.CommunityChannel>); - @override - _i16.Future> followed( - _i6.ChannelsFollowedRequest? request) => - (super.noSuchMethod( - Invocation.method( - #followed, - [request], - ), - returnValue: _i16.Future>.value( - <_i6.CommunityChannel>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.CommunityChannel>[]), - ) as _i16.Future>); - @override - _i16.Future> myFavorite( - _i6.ChannelsMyFavoriteRequest? request) => - (super.noSuchMethod( - Invocation.method( - #myFavorite, - [request], - ), - returnValue: _i16.Future>.value( - <_i6.CommunityChannel>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.CommunityChannel>[]), - ) as _i16.Future>); - @override - _i16.Future> featured() => (super.noSuchMethod( - Invocation.method( - #featured, - [], - ), - returnValue: _i16.Future>.value( - <_i6.CommunityChannel>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.CommunityChannel>[]), - ) as _i16.Future>); - @override - _i16.Future> owned( - _i6.ChannelsOwnedRequest? request) => - (super.noSuchMethod( - Invocation.method( - #owned, - [request], - ), - returnValue: _i16.Future>.value( - <_i6.CommunityChannel>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.CommunityChannel>[]), - ) as _i16.Future>); + ) as _i17.Future<_i6.Clip>); @override - _i16.Future> search( - _i6.ChannelsSearchRequest? request) => + _i17.Future delete(_i6.ClipsDeleteRequest? request) => (super.noSuchMethod( Invocation.method( - #search, + #delete, [request], ), - returnValue: _i16.Future>.value( - <_i6.CommunityChannel>[]), - returnValueForMissingStub: - _i16.Future>.value( - <_i6.CommunityChannel>[]), - ) as _i16.Future>); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future<_i6.CommunityChannel> create( - _i6.ChannelsCreateRequest? request) => + _i17.Future<_i6.Clip> update(_i6.ClipsUpdateRequest? request) => (super.noSuchMethod( Invocation.method( - #create, + #update, [request], ), - returnValue: - _i16.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_35( + returnValue: _i17.Future<_i6.Clip>.value(_FakeClip_30( this, Invocation.method( - #create, + #update, [request], ), )), - returnValueForMissingStub: - _i16.Future<_i6.CommunityChannel>.value(_FakeCommunityChannel_35( + returnValueForMissingStub: _i17.Future<_i6.Clip>.value(_FakeClip_30( this, Invocation.method( - #create, + #update, [request], ), )), - ) as _i16.Future<_i6.CommunityChannel>); + ) as _i17.Future<_i6.Clip>); @override - _i16.Future update(_i6.ChannelsUpdateRequest? request) => + _i17.Future<_i6.Clip> show(_i6.ClipsShowRequest? request) => (super.noSuchMethod( Invocation.method( - #update, + #show, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future<_i6.Clip>.value(_FakeClip_30( + this, + Invocation.method( + #show, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.Clip>.value(_FakeClip_30( + this, + Invocation.method( + #show, + [request], + ), + )), + ) as _i17.Future<_i6.Clip>); @override - _i16.Future favorite(_i6.ChannelsFavoriteRequest? request) => + _i17.Future favorite(_i6.ClipsFavoriteRequest? request) => (super.noSuchMethod( Invocation.method( #favorite, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future unfavorite(_i6.ChannelsUnfavoriteRequest? request) => + _i17.Future unfavorite(_i6.ClipsUnfavoriteRequest? request) => (super.noSuchMethod( Invocation.method( #unfavorite, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); - @override - _i16.Future follow(_i6.ChannelsFollowRequest? request) => - (super.noSuchMethod( - Invocation.method( - #follow, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); - @override - _i16.Future unfollow(_i6.ChannelsUnfollowRequest? request) => - (super.noSuchMethod( - Invocation.method( - #unfollow, - [request], - ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); } /// A class which mocks [MisskeyDrive]. @@ -2890,11 +2750,11 @@ class MockMisskeyDrive extends _i1.Mock implements _i6.MisskeyDrive { @override _i6.MisskeyDriveFiles get files => (super.noSuchMethod( Invocation.getter(#files), - returnValue: _FakeMisskeyDriveFiles_36( + returnValue: _FakeMisskeyDriveFiles_31( this, Invocation.getter(#files), ), - returnValueForMissingStub: _FakeMisskeyDriveFiles_36( + returnValueForMissingStub: _FakeMisskeyDriveFiles_31( this, Invocation.getter(#files), ), @@ -2902,11 +2762,11 @@ class MockMisskeyDrive extends _i1.Mock implements _i6.MisskeyDrive { @override _i6.MisskeyDriveFolders get folders => (super.noSuchMethod( Invocation.getter(#folders), - returnValue: _FakeMisskeyDriveFolders_37( + returnValue: _FakeMisskeyDriveFolders_32( this, Invocation.getter(#folders), ), - returnValueForMissingStub: _FakeMisskeyDriveFolders_37( + returnValueForMissingStub: _FakeMisskeyDriveFolders_32( this, Invocation.getter(#folders), ), @@ -2919,7 +2779,7 @@ class MockMisskeyDrive extends _i1.Mock implements _i6.MisskeyDrive { class MockMisskeyDriveFolders extends _i1.Mock implements _i6.MisskeyDriveFolders { @override - _i16.Future> folders( + _i17.Future> folders( _i6.DriveFoldersRequest? request) => (super.noSuchMethod( Invocation.method( @@ -2927,10 +2787,10 @@ class MockMisskeyDriveFolders extends _i1.Mock [request], ), returnValue: - _i16.Future>.value(<_i6.DriveFolder>[]), + _i17.Future>.value(<_i6.DriveFolder>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.DriveFolder>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.DriveFolder>[]), + ) as _i17.Future>); } /// A class which mocks [MisskeyDriveFiles]. @@ -2938,9 +2798,9 @@ class MockMisskeyDriveFolders extends _i1.Mock /// See the documentation for Mockito's code generation for more information. class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { @override - _i16.Future<_i6.DriveFile> create( + _i17.Future<_i6.DriveFile> create( _i6.DriveFilesCreateRequest? request, - _i23.File? fileContent, + _i14.File? fileContent, ) => (super.noSuchMethod( Invocation.method( @@ -2950,7 +2810,7 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { fileContent, ], ), - returnValue: _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + returnValue: _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #create, @@ -2961,7 +2821,7 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { ), )), returnValueForMissingStub: - _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #create, @@ -2971,9 +2831,9 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { ], ), )), - ) as _i16.Future<_i6.DriveFile>); + ) as _i17.Future<_i6.DriveFile>); @override - _i16.Future<_i6.DriveFile> createAsBinary( + _i17.Future<_i6.DriveFile> createAsBinary( _i6.DriveFilesCreateRequest? request, _i24.Uint8List? fileContent, ) => @@ -2985,7 +2845,7 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { fileContent, ], ), - returnValue: _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + returnValue: _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #createAsBinary, @@ -2996,7 +2856,7 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { ), )), returnValueForMissingStub: - _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #createAsBinary, @@ -3006,15 +2866,15 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { ], ), )), - ) as _i16.Future<_i6.DriveFile>); + ) as _i17.Future<_i6.DriveFile>); @override - _i16.Future<_i6.DriveFile> update(_i6.DriveFilesUpdateRequest? request) => + _i17.Future<_i6.DriveFile> update(_i6.DriveFilesUpdateRequest? request) => (super.noSuchMethod( Invocation.method( #update, [request], ), - returnValue: _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + returnValue: _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #update, @@ -3022,38 +2882,38 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { ), )), returnValueForMissingStub: - _i16.Future<_i6.DriveFile>.value(_FakeDriveFile_38( + _i17.Future<_i6.DriveFile>.value(_FakeDriveFile_33( this, Invocation.method( #update, [request], ), )), - ) as _i16.Future<_i6.DriveFile>); + ) as _i17.Future<_i6.DriveFile>); @override - _i16.Future delete(_i6.DriveFilesDeleteRequest? request) => + _i17.Future delete(_i6.DriveFilesDeleteRequest? request) => (super.noSuchMethod( Invocation.method( #delete, [request], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future> files(_i6.DriveFilesRequest? request) => + _i17.Future> files(_i6.DriveFilesRequest? request) => (super.noSuchMethod( Invocation.method( #files, [request], ), returnValue: - _i16.Future>.value(<_i6.DriveFile>[]), + _i17.Future>.value(<_i6.DriveFile>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.DriveFile>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.DriveFile>[]), + ) as _i17.Future>); @override - _i16.Future> find( + _i17.Future> find( _i6.DriveFilesFindRequest? request) => (super.noSuchMethod( Invocation.method( @@ -3061,46 +2921,173 @@ class MockMisskeyDriveFiles extends _i1.Mock implements _i6.MisskeyDriveFiles { [request], ), returnValue: - _i16.Future>.value(<_i6.DriveFile>[]), + _i17.Future>.value(<_i6.DriveFile>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.DriveFile>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.DriveFile>[]), + ) as _i17.Future>); } -/// A class which mocks [MisskeyHashtags]. +/// A class which mocks [MisskeyFederation]. /// /// See the documentation for Mockito's code generation for more information. -class MockMisskeyHashtags extends _i1.Mock implements _i6.MisskeyHashtags { +class MockMisskeyFederation extends _i1.Mock implements _i6.MisskeyFederation { @override - _i16.Future> list(_i6.HashtagsListRequest? request) => + _i17.Future<_i6.FederationShowInstanceResponse> showInstance( + _i6.FederationShowInstanceRequest? request) => (super.noSuchMethod( Invocation.method( - #list, + #showInstance, [request], ), - returnValue: _i16.Future>.value(<_i6.Hashtag>[]), + returnValue: _i17.Future<_i6.FederationShowInstanceResponse>.value( + _FakeFederationShowInstanceResponse_34( + this, + Invocation.method( + #showInstance, + [request], + ), + )), returnValueForMissingStub: - _i16.Future>.value(<_i6.Hashtag>[]), - ) as _i16.Future>); - @override - _i16.Future> search(_i6.HashtagsSearchRequest? request) => - (super.noSuchMethod( + _i17.Future<_i6.FederationShowInstanceResponse>.value( + _FakeFederationShowInstanceResponse_34( + this, + Invocation.method( + #showInstance, + [request], + ), + )), + ) as _i17.Future<_i6.FederationShowInstanceResponse>); + @override + _i17.Future> users(_i6.FederationUsersRequest? request) => + (super.noSuchMethod( + Invocation.method( + #users, + [request], + ), + returnValue: _i17.Future>.value(<_i6.User>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); +} + +/// A class which mocks [MisskeyFollowing]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyFollowing extends _i1.Mock implements _i6.MisskeyFollowing { + @override + _i6.MisskeyFollowingRequests get requests => (super.noSuchMethod( + Invocation.getter(#requests), + returnValue: _FakeMisskeyFollowingRequests_35( + this, + Invocation.getter(#requests), + ), + returnValueForMissingStub: _FakeMisskeyFollowingRequests_35( + this, + Invocation.getter(#requests), + ), + ) as _i6.MisskeyFollowingRequests); + @override + _i17.Future<_i6.User> create(_i6.FollowingCreateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #create, + [request], + ), + returnValue: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #create, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #create, + [request], + ), + )), + ) as _i17.Future<_i6.User>); + @override + _i17.Future<_i6.User> delete(_i6.FollowingDeleteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #delete, + [request], + ), + returnValue: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #delete, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #delete, + [request], + ), + )), + ) as _i17.Future<_i6.User>); + @override + _i17.Future<_i6.User> invalidate(_i6.FollowingInvalidateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #invalidate, + [request], + ), + returnValue: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #invalidate, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.User>.value(_FakeUser_36( + this, + Invocation.method( + #invalidate, + [request], + ), + )), + ) as _i17.Future<_i6.User>); +} + +/// A class which mocks [MisskeyHashtags]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyHashtags extends _i1.Mock implements _i6.MisskeyHashtags { + @override + _i17.Future> list(_i6.HashtagsListRequest? request) => + (super.noSuchMethod( + Invocation.method( + #list, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Hashtag>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Hashtag>[]), + ) as _i17.Future>); + @override + _i17.Future> search(_i6.HashtagsSearchRequest? request) => + (super.noSuchMethod( Invocation.method( #search, [request], ), - returnValue: _i16.Future>.value([]), + returnValue: _i17.Future>.value([]), returnValueForMissingStub: - _i16.Future>.value([]), - ) as _i16.Future>); + _i17.Future>.value([]), + ) as _i17.Future>); @override - _i16.Future<_i6.Hashtag> show(_i6.HashtagsShowRequest? request) => + _i17.Future<_i6.Hashtag> show(_i6.HashtagsShowRequest? request) => (super.noSuchMethod( Invocation.method( #show, [request], ), - returnValue: _i16.Future<_i6.Hashtag>.value(_FakeHashtag_39( + returnValue: _i17.Future<_i6.Hashtag>.value(_FakeHashtag_37( this, Invocation.method( #show, @@ -3108,987 +3095,2385 @@ class MockMisskeyHashtags extends _i1.Mock implements _i6.MisskeyHashtags { ), )), returnValueForMissingStub: - _i16.Future<_i6.Hashtag>.value(_FakeHashtag_39( + _i17.Future<_i6.Hashtag>.value(_FakeHashtag_37( this, Invocation.method( #show, [request], ), )), - ) as _i16.Future<_i6.Hashtag>); + ) as _i17.Future<_i6.Hashtag>); @override - _i16.Future> trend() => + _i17.Future> trend() => (super.noSuchMethod( Invocation.method( #trend, [], ), - returnValue: _i16.Future>.value( + returnValue: _i17.Future>.value( <_i6.HashtagsTrendResponse>[]), returnValueForMissingStub: - _i16.Future>.value( + _i17.Future>.value( <_i6.HashtagsTrendResponse>[]), - ) as _i16.Future>); + ) as _i17.Future>); @override - _i16.Future> users(_i6.HashtagsUsersRequest? request) => + _i17.Future> users(_i6.HashtagsUsersRequest? request) => (super.noSuchMethod( Invocation.method( #users, [request], ), - returnValue: _i16.Future>.value(<_i6.User>[]), + returnValue: _i17.Future>.value(<_i6.User>[]), returnValueForMissingStub: - _i16.Future>.value(<_i6.User>[]), - ) as _i16.Future>); + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); } -/// A class which mocks [Dio]. +/// A class which mocks [MisskeyI]. /// /// See the documentation for Mockito's code generation for more information. -class MockDio extends _i1.Mock implements _i25.Dio { +class MockMisskeyI extends _i1.Mock implements _i6.MisskeyI { @override - _i9.BaseOptions get options => (super.noSuchMethod( - Invocation.getter(#options), - returnValue: _FakeBaseOptions_40( - this, - Invocation.getter(#options), + _i17.Future<_i6.IResponse> i() => (super.noSuchMethod( + Invocation.method( + #i, + [], ), - returnValueForMissingStub: _FakeBaseOptions_40( + returnValue: _i17.Future<_i6.IResponse>.value(_FakeIResponse_38( this, - Invocation.getter(#options), + Invocation.method( + #i, + [], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.IResponse>.value(_FakeIResponse_38( + this, + Invocation.method( + #i, + [], + ), + )), + ) as _i17.Future<_i6.IResponse>); + @override + _i17.Future> notifications( + _i6.INotificationsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #notifications, + [request], ), - ) as _i9.BaseOptions); + returnValue: _i17.Future>.value( + <_i6.INotificationsResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.INotificationsResponse>[]), + ) as _i17.Future>); @override - set options(_i9.BaseOptions? _options) => super.noSuchMethod( - Invocation.setter( - #options, - _options, + _i17.Future readAnnouncement(_i6.IReadAnnouncementRequest? request) => + (super.noSuchMethod( + Invocation.method( + #readAnnouncement, + [request], ), - returnValueForMissingStub: null, - ); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i10.HttpClientAdapter get httpClientAdapter => (super.noSuchMethod( - Invocation.getter(#httpClientAdapter), - returnValue: _FakeHttpClientAdapter_41( - this, - Invocation.getter(#httpClientAdapter), + _i17.Future> favorites( + _i6.IFavoritesRequest? request) => + (super.noSuchMethod( + Invocation.method( + #favorites, + [request], ), - returnValueForMissingStub: _FakeHttpClientAdapter_41( - this, - Invocation.getter(#httpClientAdapter), + returnValue: _i17.Future>.value( + <_i6.IFavoritesResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.IFavoritesResponse>[]), + ) as _i17.Future>); + @override + _i17.Future<_i6.IResponse> update(_i6.IUpdateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #update, + [request], ), - ) as _i10.HttpClientAdapter); + returnValue: _i17.Future<_i6.IResponse>.value(_FakeIResponse_38( + this, + Invocation.method( + #update, + [request], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.IResponse>.value(_FakeIResponse_38( + this, + Invocation.method( + #update, + [request], + ), + )), + ) as _i17.Future<_i6.IResponse>); +} + +/// A class which mocks [MisskeyNotes]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyNotes extends _i1.Mock implements _i6.MisskeyNotes { @override - set httpClientAdapter(_i10.HttpClientAdapter? _httpClientAdapter) => - super.noSuchMethod( - Invocation.setter( - #httpClientAdapter, - _httpClientAdapter, + _i6.MisskeyNotesReactions get reactions => (super.noSuchMethod( + Invocation.getter(#reactions), + returnValue: _FakeMisskeyNotesReactions_39( + this, + Invocation.getter(#reactions), ), - returnValueForMissingStub: null, - ); + returnValueForMissingStub: _FakeMisskeyNotesReactions_39( + this, + Invocation.getter(#reactions), + ), + ) as _i6.MisskeyNotesReactions); @override - _i11.Transformer get transformer => (super.noSuchMethod( - Invocation.getter(#transformer), - returnValue: _FakeTransformer_42( + _i6.MisskeyNotesFavorites get favorites => (super.noSuchMethod( + Invocation.getter(#favorites), + returnValue: _FakeMisskeyNotesFavorites_40( this, - Invocation.getter(#transformer), + Invocation.getter(#favorites), ), - returnValueForMissingStub: _FakeTransformer_42( + returnValueForMissingStub: _FakeMisskeyNotesFavorites_40( this, - Invocation.getter(#transformer), + Invocation.getter(#favorites), ), - ) as _i11.Transformer); + ) as _i6.MisskeyNotesFavorites); @override - set transformer(_i11.Transformer? _transformer) => super.noSuchMethod( - Invocation.setter( - #transformer, - _transformer, + _i6.MisskeyNotesPolls get polls => (super.noSuchMethod( + Invocation.getter(#polls), + returnValue: _FakeMisskeyNotesPolls_41( + this, + Invocation.getter(#polls), ), - returnValueForMissingStub: null, - ); + returnValueForMissingStub: _FakeMisskeyNotesPolls_41( + this, + Invocation.getter(#polls), + ), + ) as _i6.MisskeyNotesPolls); @override - _i12.Interceptors get interceptors => (super.noSuchMethod( - Invocation.getter(#interceptors), - returnValue: _FakeInterceptors_43( + _i6.MisskeyNotesThreadMuting get threadMuting => (super.noSuchMethod( + Invocation.getter(#threadMuting), + returnValue: _FakeMisskeyNotesThreadMuting_42( this, - Invocation.getter(#interceptors), + Invocation.getter(#threadMuting), ), - returnValueForMissingStub: _FakeInterceptors_43( + returnValueForMissingStub: _FakeMisskeyNotesThreadMuting_42( this, - Invocation.getter(#interceptors), + Invocation.getter(#threadMuting), ), - ) as _i12.Interceptors); + ) as _i6.MisskeyNotesThreadMuting); @override - void close({bool? force = false}) => super.noSuchMethod( + _i17.Future create(_i6.NotesCreateRequest? request) => + (super.noSuchMethod( Invocation.method( - #close, - [], - {#force: force}, + #create, + [request], ), - returnValueForMissingStub: null, - ); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future update(_i6.NotesUpdateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #update, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future delete(_i6.NotesDeleteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #delete, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future> notes(_i6.NotesRequest? request) => + (super.noSuchMethod( + Invocation.method( + #notes, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future<_i6.Note> show(_i6.NotesShowRequest? request) => + (super.noSuchMethod( + Invocation.method( + #show, + [request], + ), + returnValue: _i17.Future<_i6.Note>.value(_FakeNote_43( + this, + Invocation.method( + #show, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.Note>.value(_FakeNote_43( + this, + Invocation.method( + #show, + [request], + ), + )), + ) as _i17.Future<_i6.Note>); + @override + _i17.Future> homeTimeline( + _i6.NotesTimelineRequest? request) => + (super.noSuchMethod( + Invocation.method( + #homeTimeline, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> localTimeline( + _i6.NotesLocalTimelineRequest? request) => + (super.noSuchMethod( + Invocation.method( + #localTimeline, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> hybridTimeline( + _i6.NotesHybridTimelineRequest? request) => + (super.noSuchMethod( + Invocation.method( + #hybridTimeline, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> globalTimeline( + _i6.NotesGlobalTimelineRequest? request) => + (super.noSuchMethod( + Invocation.method( + #globalTimeline, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> userListTimeline( + _i6.UserListTimelineRequest? request) => + (super.noSuchMethod( + Invocation.method( + #userListTimeline, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future<_i6.NotesStateResponse> state(_i6.NotesStateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #state, + [request], + ), + returnValue: _i17.Future<_i6.NotesStateResponse>.value( + _FakeNotesStateResponse_44( + this, + Invocation.method( + #state, + [request], + ), + )), + returnValueForMissingStub: _i17.Future<_i6.NotesStateResponse>.value( + _FakeNotesStateResponse_44( + this, + Invocation.method( + #state, + [request], + ), + )), + ) as _i17.Future<_i6.NotesStateResponse>); + @override + _i17.Future> search(_i6.NotesSearchRequest? request) => + (super.noSuchMethod( + Invocation.method( + #search, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> searchByTag( + _i6.NotesSearchByTagRequest? request) => + (super.noSuchMethod( + Invocation.method( + #searchByTag, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> renotes(_i6.NotesRenoteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #renotes, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> replies(_i6.NotesRepliesRequest? request) => + (super.noSuchMethod( + Invocation.method( + #replies, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> children(_i6.NotesChildrenRequest? request) => + (super.noSuchMethod( + Invocation.method( + #children, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> conversation( + _i6.NotesConversationRequest? request) => + (super.noSuchMethod( + Invocation.method( + #conversation, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> featured(_i6.NotesFeaturedRequest? request) => + (super.noSuchMethod( + Invocation.method( + #featured, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> mentions(_i6.NotesMentionsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #mentions, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> clips(_i6.NotesClipsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #clips, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Clip>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Clip>[]), + ) as _i17.Future>); + @override + _i17.Future unrenote(_i6.NotesUnrenoteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #unrenote, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyNotesFavorites]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyNotesFavorites extends _i1.Mock + implements _i6.MisskeyNotesFavorites { + @override + _i17.Future create(_i6.NotesFavoritesCreateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #create, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future delete(_i6.NotesFavoritesDeleteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #delete, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyNotesPolls]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyNotesPolls extends _i1.Mock implements _i6.MisskeyNotesPolls { + @override + _i17.Future vote(_i6.NotesPollsVoteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #vote, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future> recommendation( + _i6.NotesPollsRecommendationRequest? request) => + (super.noSuchMethod( + Invocation.method( + #recommendation, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); +} + +/// A class which mocks [MisskeyRenoteMute]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyRenoteMute extends _i1.Mock implements _i6.MisskeyRenoteMute { + @override + _i17.Future create(_i6.RenoteMuteCreateRequest? request) => + (super.noSuchMethod( + Invocation.method( + #create, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future delete(_i6.RenoteMuteDeleteRequest? request) => + (super.noSuchMethod( + Invocation.method( + #delete, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); +} + +/// A class which mocks [MisskeyRoles]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyRoles extends _i1.Mock implements _i6.MisskeyRoles { + @override + _i17.Future> list() => (super.noSuchMethod( + Invocation.method( + #list, + [], + ), + returnValue: _i17.Future>.value( + <_i6.RolesListResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.RolesListResponse>[]), + ) as _i17.Future>); + @override + _i17.Future> users( + _i6.RolesUsersRequest? request) => + (super.noSuchMethod( + Invocation.method( + #users, + [request], + ), + returnValue: _i17.Future>.value( + <_i6.RolesUsersResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.RolesUsersResponse>[]), + ) as _i17.Future>); + @override + _i17.Future<_i6.RolesListResponse> show(_i6.RolesShowRequest? request) => + (super.noSuchMethod( + Invocation.method( + #show, + [request], + ), + returnValue: + _i17.Future<_i6.RolesListResponse>.value(_FakeRolesListResponse_45( + this, + Invocation.method( + #show, + [request], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.RolesListResponse>.value(_FakeRolesListResponse_45( + this, + Invocation.method( + #show, + [request], + ), + )), + ) as _i17.Future<_i6.RolesListResponse>); + @override + _i17.Future> notes(_i6.RolesNotesRequest? request) => + (super.noSuchMethod( + Invocation.method( + #notes, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); +} + +/// A class which mocks [MisskeyUsers]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockMisskeyUsers extends _i1.Mock implements _i6.MisskeyUsers { + @override + _i6.MisskeyUsersLists get list => (super.noSuchMethod( + Invocation.getter(#list), + returnValue: _FakeMisskeyUsersLists_46( + this, + Invocation.getter(#list), + ), + returnValueForMissingStub: _FakeMisskeyUsersLists_46( + this, + Invocation.getter(#list), + ), + ) as _i6.MisskeyUsersLists); + @override + _i17.Future<_i6.UsersShowResponse> show(_i6.UsersShowRequest? request) => + (super.noSuchMethod( + Invocation.method( + #show, + [request], + ), + returnValue: + _i17.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_47( + this, + Invocation.method( + #show, + [request], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_47( + this, + Invocation.method( + #show, + [request], + ), + )), + ) as _i17.Future<_i6.UsersShowResponse>); + @override + _i17.Future> showByIds( + _i6.UsersShowByIdsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #showByIds, + [request], + ), + returnValue: _i17.Future>.value( + <_i6.UsersShowResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.UsersShowResponse>[]), + ) as _i17.Future>); + @override + _i17.Future<_i6.UsersShowResponse> showByName( + _i6.UsersShowByUserNameRequest? request) => + (super.noSuchMethod( + Invocation.method( + #showByName, + [request], + ), + returnValue: + _i17.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_47( + this, + Invocation.method( + #showByName, + [request], + ), + )), + returnValueForMissingStub: + _i17.Future<_i6.UsersShowResponse>.value(_FakeUsersShowResponse_47( + this, + Invocation.method( + #showByName, + [request], + ), + )), + ) as _i17.Future<_i6.UsersShowResponse>); + @override + _i17.Future> notes(_i6.UsersNotesRequest? request) => + (super.noSuchMethod( + Invocation.method( + #notes, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Note>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Note>[]), + ) as _i17.Future>); + @override + _i17.Future> clips(_i6.UsersClipsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #clips, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Clip>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Clip>[]), + ) as _i17.Future>); + @override + _i17.Future> followers( + _i6.UsersFollowersRequest? request) => + (super.noSuchMethod( + Invocation.method( + #followers, + [request], + ), + returnValue: + _i17.Future>.value(<_i6.Following>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Following>[]), + ) as _i17.Future>); + @override + _i17.Future> following( + _i6.UsersFollowingRequest? request) => + (super.noSuchMethod( + Invocation.method( + #following, + [request], + ), + returnValue: + _i17.Future>.value(<_i6.Following>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Following>[]), + ) as _i17.Future>); + @override + _i17.Future reportAbuse(_i6.UsersReportAbuseRequest? request) => + (super.noSuchMethod( + Invocation.method( + #reportAbuse, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future> reactions( + _i6.UsersReactionsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #reactions, + [request], + ), + returnValue: _i17.Future>.value( + <_i6.UsersReactionsResponse>[]), + returnValueForMissingStub: + _i17.Future>.value( + <_i6.UsersReactionsResponse>[]), + ) as _i17.Future>); + @override + _i17.Future> search(_i6.UsersSearchRequest? request) => + (super.noSuchMethod( + Invocation.method( + #search, + [request], + ), + returnValue: _i17.Future>.value(<_i6.User>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); + @override + _i17.Future> recommendation( + _i6.UsersRecommendationRequest? request) => + (super.noSuchMethod( + Invocation.method( + #recommendation, + [request], + ), + returnValue: _i17.Future>.value(<_i6.User>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); + @override + _i17.Future> users(_i6.UsersUsersRequest? request) => + (super.noSuchMethod( + Invocation.method( + #users, + [request], + ), + returnValue: _i17.Future>.value(<_i6.User>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.User>[]), + ) as _i17.Future>); + @override + _i17.Future updateMemo(_i6.UsersUpdateMemoRequest? request) => + (super.noSuchMethod( + Invocation.method( + #updateMemo, + [request], + ), + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); + @override + _i17.Future> flashs(_i6.UsersFlashsRequest? request) => + (super.noSuchMethod( + Invocation.method( + #flashs, + [request], + ), + returnValue: _i17.Future>.value(<_i6.Flash>[]), + returnValueForMissingStub: + _i17.Future>.value(<_i6.Flash>[]), + ) as _i17.Future>); +} + +/// A class which mocks [Dio]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockDio extends _i1.Mock implements _i25.Dio { + @override + _i9.BaseOptions get options => (super.noSuchMethod( + Invocation.getter(#options), + returnValue: _FakeBaseOptions_48( + this, + Invocation.getter(#options), + ), + returnValueForMissingStub: _FakeBaseOptions_48( + this, + Invocation.getter(#options), + ), + ) as _i9.BaseOptions); + @override + set options(_i9.BaseOptions? _options) => super.noSuchMethod( + Invocation.setter( + #options, + _options, + ), + returnValueForMissingStub: null, + ); + @override + _i10.HttpClientAdapter get httpClientAdapter => (super.noSuchMethod( + Invocation.getter(#httpClientAdapter), + returnValue: _FakeHttpClientAdapter_49( + this, + Invocation.getter(#httpClientAdapter), + ), + returnValueForMissingStub: _FakeHttpClientAdapter_49( + this, + Invocation.getter(#httpClientAdapter), + ), + ) as _i10.HttpClientAdapter); + @override + set httpClientAdapter(_i10.HttpClientAdapter? _httpClientAdapter) => + super.noSuchMethod( + Invocation.setter( + #httpClientAdapter, + _httpClientAdapter, + ), + returnValueForMissingStub: null, + ); + @override + _i11.Transformer get transformer => (super.noSuchMethod( + Invocation.getter(#transformer), + returnValue: _FakeTransformer_50( + this, + Invocation.getter(#transformer), + ), + returnValueForMissingStub: _FakeTransformer_50( + this, + Invocation.getter(#transformer), + ), + ) as _i11.Transformer); + @override + set transformer(_i11.Transformer? _transformer) => super.noSuchMethod( + Invocation.setter( + #transformer, + _transformer, + ), + returnValueForMissingStub: null, + ); + @override + _i12.Interceptors get interceptors => (super.noSuchMethod( + Invocation.getter(#interceptors), + returnValue: _FakeInterceptors_51( + this, + Invocation.getter(#interceptors), + ), + returnValueForMissingStub: _FakeInterceptors_51( + this, + Invocation.getter(#interceptors), + ), + ) as _i12.Interceptors); + @override + void close({bool? force = false}) => super.noSuchMethod( + Invocation.method( + #close, + [], + {#force: force}, + ), + returnValueForMissingStub: null, + ); + @override + _i17.Future<_i13.Response> get( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #get, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #get, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #get, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> getUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #getUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #getUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #getUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> post( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #post, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #post, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #post, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> postUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #postUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #postUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #postUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> put( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #put, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #put, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #put, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> putUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #putUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #putUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #putUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> head( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + }) => + (super.noSuchMethod( + Invocation.method( + #head, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #head, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #head, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> headUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + }) => + (super.noSuchMethod( + Invocation.method( + #headUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #headUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #headUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> delete( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + }) => + (super.noSuchMethod( + Invocation.method( + #delete, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #delete, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #delete, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> deleteUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + }) => + (super.noSuchMethod( + Invocation.method( + #deleteUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #deleteUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #deleteUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> patch( + String? path, { + Object? data, + Map? queryParameters, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #patch, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #patch, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #patch, + [path], + { + #data: data, + #queryParameters: queryParameters, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); + @override + _i17.Future<_i13.Response> patchUri( + Uri? uri, { + Object? data, + _i9.Options? options, + _i26.CancelToken? cancelToken, + _i9.ProgressCallback? onSendProgress, + _i9.ProgressCallback? onReceiveProgress, + }) => + (super.noSuchMethod( + Invocation.method( + #patchUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #patchUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + returnValueForMissingStub: + _i17.Future<_i13.Response>.value(_FakeResponse_52( + this, + Invocation.method( + #patchUri, + [uri], + { + #data: data, + #options: options, + #cancelToken: cancelToken, + #onSendProgress: onSendProgress, + #onReceiveProgress: onReceiveProgress, + }, + ), + )), + ) as _i17.Future<_i13.Response>); @override - _i16.Future<_i13.Response> get( - String? path, { - Object? data, + _i17.Future<_i13.Response> download( + String? urlPath, + dynamic savePath, { + _i9.ProgressCallback? onReceiveProgress, Map? queryParameters, - _i9.Options? options, _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onReceiveProgress, + bool? deleteOnError = true, + String? lengthHeader = r'content-length', + Object? data, + _i9.Options? options, }) => (super.noSuchMethod( Invocation.method( - #get, - [path], + #download, + [ + urlPath, + savePath, + ], { - #data: data, + #onReceiveProgress: onReceiveProgress, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, + #data: data, + #options: options, }, ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #get, - [path], + #download, + [ + urlPath, + savePath, + ], { - #data: data, + #onReceiveProgress: onReceiveProgress, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, + #data: data, + #options: options, }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #get, - [path], + #download, + [ + urlPath, + savePath, + ], { - #data: data, + #onReceiveProgress: onReceiveProgress, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, + #data: data, + #options: options, }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i13.Response>); @override - _i16.Future<_i13.Response> getUri( - Uri? uri, { + _i17.Future<_i13.Response> downloadUri( + Uri? uri, + dynamic savePath, { + _i9.ProgressCallback? onReceiveProgress, + _i26.CancelToken? cancelToken, + bool? deleteOnError = true, + String? lengthHeader = r'content-length', Object? data, _i9.Options? options, - _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onReceiveProgress, }) => (super.noSuchMethod( Invocation.method( - #getUri, - [uri], + #downloadUri, + [ + uri, + savePath, + ], { + #onReceiveProgress: onReceiveProgress, + #cancelToken: cancelToken, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, #data: data, #options: options, - #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, }, ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #getUri, - [uri], + #downloadUri, + [ + uri, + savePath, + ], { + #onReceiveProgress: onReceiveProgress, + #cancelToken: cancelToken, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, #data: data, #options: options, - #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #getUri, - [uri], + #downloadUri, + [ + uri, + savePath, + ], { + #onReceiveProgress: onReceiveProgress, + #cancelToken: cancelToken, + #deleteOnError: deleteOnError, + #lengthHeader: lengthHeader, #data: data, #options: options, - #cancelToken: cancelToken, - #onReceiveProgress: onReceiveProgress, }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i13.Response>); @override - _i16.Future<_i13.Response> post( + _i17.Future<_i13.Response> request( String? path, { Object? data, Map? queryParameters, - _i9.Options? options, _i26.CancelToken? cancelToken, + _i9.Options? options, _i9.ProgressCallback? onSendProgress, _i9.ProgressCallback? onReceiveProgress, }) => (super.noSuchMethod( Invocation.method( - #post, + #request, [path], { #data: data, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #post, + #request, [path], { #data: data, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #post, + #request, [path], { #data: data, #queryParameters: queryParameters, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i13.Response>); @override - _i16.Future<_i13.Response> postUri( + _i17.Future<_i13.Response> requestUri( Uri? uri, { Object? data, - _i9.Options? options, _i26.CancelToken? cancelToken, + _i9.Options? options, _i9.ProgressCallback? onSendProgress, _i9.ProgressCallback? onReceiveProgress, }) => (super.noSuchMethod( Invocation.method( - #postUri, + #requestUri, [uri], { #data: data, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #postUri, + #requestUri, [uri], { #data: data, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #postUri, + #requestUri, [uri], { #data: data, - #options: options, #cancelToken: cancelToken, + #options: options, #onSendProgress: onSendProgress, #onReceiveProgress: onReceiveProgress, }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i13.Response>); @override - _i16.Future<_i13.Response> put( - String? path, { - Object? data, - Map? queryParameters, - _i9.Options? options, - _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => + _i17.Future<_i13.Response> fetch(_i9.RequestOptions? requestOptions) => (super.noSuchMethod( Invocation.method( - #put, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #fetch, + [requestOptions], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #put, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #fetch, + [requestOptions], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i13.Response>.value(_FakeResponse_52( this, Invocation.method( - #put, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #fetch, + [requestOptions], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i13.Response>); +} + +/// A class which mocks [HttpClient]. +/// +/// See the documentation for Mockito's code generation for more information. +class MockHttpClient extends _i1.Mock implements _i14.HttpClient { @override - _i16.Future<_i13.Response> putUri( - Uri? uri, { - Object? data, - _i9.Options? options, - _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => + Duration get idleTimeout => (super.noSuchMethod( + Invocation.getter(#idleTimeout), + returnValue: _FakeDuration_53( + this, + Invocation.getter(#idleTimeout), + ), + returnValueForMissingStub: _FakeDuration_53( + this, + Invocation.getter(#idleTimeout), + ), + ) as Duration); + @override + set idleTimeout(Duration? _idleTimeout) => super.noSuchMethod( + Invocation.setter( + #idleTimeout, + _idleTimeout, + ), + returnValueForMissingStub: null, + ); + @override + set connectionTimeout(Duration? _connectionTimeout) => super.noSuchMethod( + Invocation.setter( + #connectionTimeout, + _connectionTimeout, + ), + returnValueForMissingStub: null, + ); + @override + set maxConnectionsPerHost(int? _maxConnectionsPerHost) => super.noSuchMethod( + Invocation.setter( + #maxConnectionsPerHost, + _maxConnectionsPerHost, + ), + returnValueForMissingStub: null, + ); + @override + bool get autoUncompress => (super.noSuchMethod( + Invocation.getter(#autoUncompress), + returnValue: false, + returnValueForMissingStub: false, + ) as bool); + @override + set autoUncompress(bool? _autoUncompress) => super.noSuchMethod( + Invocation.setter( + #autoUncompress, + _autoUncompress, + ), + returnValueForMissingStub: null, + ); + @override + set userAgent(String? _userAgent) => super.noSuchMethod( + Invocation.setter( + #userAgent, + _userAgent, + ), + returnValueForMissingStub: null, + ); + @override + set authenticate( + _i17.Future Function( + Uri, + String, + String?, + )? f) => + super.noSuchMethod( + Invocation.setter( + #authenticate, + f, + ), + returnValueForMissingStub: null, + ); + @override + set connectionFactory( + _i17.Future<_i14.ConnectionTask<_i14.Socket>> Function( + Uri, + String?, + int?, + )? f) => + super.noSuchMethod( + Invocation.setter( + #connectionFactory, + f, + ), + returnValueForMissingStub: null, + ); + @override + set findProxy(String Function(Uri)? f) => super.noSuchMethod( + Invocation.setter( + #findProxy, + f, + ), + returnValueForMissingStub: null, + ); + @override + set authenticateProxy( + _i17.Future Function( + String, + int, + String, + String?, + )? f) => + super.noSuchMethod( + Invocation.setter( + #authenticateProxy, + f, + ), + returnValueForMissingStub: null, + ); + @override + set badCertificateCallback( + bool Function( + _i14.X509Certificate, + String, + int, + )? callback) => + super.noSuchMethod( + Invocation.setter( + #badCertificateCallback, + callback, + ), + returnValueForMissingStub: null, + ); + @override + set keyLog(dynamic Function(String)? callback) => super.noSuchMethod( + Invocation.setter( + #keyLog, + callback, + ), + returnValueForMissingStub: null, + ); + @override + _i17.Future<_i14.HttpClientRequest> open( + String? method, + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #putUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #open, + [ + method, + host, + port, + path, + ], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #putUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #open, + [ + method, + host, + port, + path, + ], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #putUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #open, + [ + method, + host, + port, + path, + ], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> head( - String? path, { - Object? data, - Map? queryParameters, - _i9.Options? options, - _i26.CancelToken? cancelToken, - }) => + _i17.Future<_i14.HttpClientRequest> openUrl( + String? method, + Uri? url, + ) => (super.noSuchMethod( Invocation.method( - #head, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #openUrl, + [ + method, + url, + ], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #head, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #openUrl, + [ + method, + url, + ], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #head, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #openUrl, + [ + method, + url, + ], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> headUri( - Uri? uri, { - Object? data, - _i9.Options? options, - _i26.CancelToken? cancelToken, - }) => + _i17.Future<_i14.HttpClientRequest> get( + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #headUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #get, + [ + host, + port, + path, + ], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #headUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #get, + [ + host, + port, + path, + ], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #headUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #get, + [ + host, + port, + path, + ], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> delete( - String? path, { - Object? data, - Map? queryParameters, - _i9.Options? options, - _i26.CancelToken? cancelToken, - }) => - (super.noSuchMethod( + _i17.Future<_i14.HttpClientRequest> getUrl(Uri? url) => (super.noSuchMethod( Invocation.method( - #delete, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #getUrl, + [url], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #delete, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #getUrl, + [url], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #delete, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - }, + #getUrl, + [url], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> deleteUri( - Uri? uri, { - Object? data, - _i9.Options? options, - _i26.CancelToken? cancelToken, - }) => + _i17.Future<_i14.HttpClientRequest> post( + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #deleteUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #post, + [ + host, + port, + path, + ], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #deleteUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #post, + [ + host, + port, + path, + ], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #deleteUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - }, + #post, + [ + host, + port, + path, + ], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> patch( - String? path, { - Object? data, - Map? queryParameters, - _i9.Options? options, - _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => - (super.noSuchMethod( + _i17.Future<_i14.HttpClientRequest> postUrl(Uri? url) => (super.noSuchMethod( Invocation.method( - #patch, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #postUrl, + [url], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #patch, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #postUrl, + [url], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #patch, - [path], - { - #data: data, - #queryParameters: queryParameters, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #postUrl, + [url], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> patchUri( - Uri? uri, { - Object? data, - _i9.Options? options, - _i26.CancelToken? cancelToken, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => + _i17.Future<_i14.HttpClientRequest> put( + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #patchUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #put, + [ + host, + port, + path, + ], + ), + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( + this, + Invocation.method( + #put, + [ + host, + port, + path, + ], + ), + )), + returnValueForMissingStub: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( + this, + Invocation.method( + #put, + [ + host, + port, + path, + ], + ), + )), + ) as _i17.Future<_i14.HttpClientRequest>); + @override + _i17.Future<_i14.HttpClientRequest> putUrl(Uri? url) => (super.noSuchMethod( + Invocation.method( + #putUrl, + [url], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #patchUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #putUrl, + [url], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #patchUri, - [uri], - { - #data: data, - #options: options, - #cancelToken: cancelToken, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #putUrl, + [url], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> download( - String? urlPath, - dynamic savePath, { - _i9.ProgressCallback? onReceiveProgress, - Map? queryParameters, - _i26.CancelToken? cancelToken, - bool? deleteOnError = true, - String? lengthHeader = r'content-length', - Object? data, - _i9.Options? options, - }) => + _i17.Future<_i14.HttpClientRequest> delete( + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #download, + #delete, [ - urlPath, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), returnValue: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #download, + #delete, [ - urlPath, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #download, + #delete, [ - urlPath, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> downloadUri( - Uri? uri, - dynamic savePath, { - _i9.ProgressCallback? onReceiveProgress, - _i26.CancelToken? cancelToken, - bool? deleteOnError = true, - String? lengthHeader = r'content-length', - Object? data, - _i9.Options? options, - }) => + _i17.Future<_i14.HttpClientRequest> deleteUrl(Uri? url) => (super.noSuchMethod( Invocation.method( - #downloadUri, + #deleteUrl, + [url], + ), + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( + this, + Invocation.method( + #deleteUrl, + [url], + ), + )), + returnValueForMissingStub: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( + this, + Invocation.method( + #deleteUrl, + [url], + ), + )), + ) as _i17.Future<_i14.HttpClientRequest>); + @override + _i17.Future<_i14.HttpClientRequest> patch( + String? host, + int? port, + String? path, + ) => + (super.noSuchMethod( + Invocation.method( + #patch, [ - uri, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), returnValue: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #downloadUri, + #patch, [ - uri, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #downloadUri, + #patch, [ - uri, - savePath, + host, + port, + path, ], - { - #onReceiveProgress: onReceiveProgress, - #cancelToken: cancelToken, - #deleteOnError: deleteOnError, - #lengthHeader: lengthHeader, - #data: data, - #options: options, - }, ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> request( - String? path, { - Object? data, - Map? queryParameters, - _i26.CancelToken? cancelToken, - _i9.Options? options, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => - (super.noSuchMethod( + _i17.Future<_i14.HttpClientRequest> patchUrl(Uri? url) => (super.noSuchMethod( Invocation.method( - #request, - [path], - { - #data: data, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #patchUrl, + [url], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #request, - [path], - { - #data: data, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #patchUrl, + [url], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #request, - [path], - { - #data: data, - #queryParameters: queryParameters, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #patchUrl, + [url], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> requestUri( - Uri? uri, { - Object? data, - _i26.CancelToken? cancelToken, - _i9.Options? options, - _i9.ProgressCallback? onSendProgress, - _i9.ProgressCallback? onReceiveProgress, - }) => + _i17.Future<_i14.HttpClientRequest> head( + String? host, + int? port, + String? path, + ) => (super.noSuchMethod( Invocation.method( - #requestUri, - [uri], - { - #data: data, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #head, + [ + host, + port, + path, + ], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #requestUri, - [uri], - { - #data: data, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #head, + [ + host, + port, + path, + ], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #requestUri, - [uri], - { - #data: data, - #cancelToken: cancelToken, - #options: options, - #onSendProgress: onSendProgress, - #onReceiveProgress: onReceiveProgress, - }, + #head, + [ + host, + port, + path, + ], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); @override - _i16.Future<_i13.Response> fetch(_i9.RequestOptions? requestOptions) => - (super.noSuchMethod( + _i17.Future<_i14.HttpClientRequest> headUrl(Uri? url) => (super.noSuchMethod( Invocation.method( - #fetch, - [requestOptions], + #headUrl, + [url], ), - returnValue: _i16.Future<_i13.Response>.value(_FakeResponse_44( + returnValue: + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #fetch, - [requestOptions], + #headUrl, + [url], ), )), returnValueForMissingStub: - _i16.Future<_i13.Response>.value(_FakeResponse_44( + _i17.Future<_i14.HttpClientRequest>.value(_FakeHttpClientRequest_54( this, Invocation.method( - #fetch, - [requestOptions], + #headUrl, + [url], ), )), - ) as _i16.Future<_i13.Response>); + ) as _i17.Future<_i14.HttpClientRequest>); + @override + void addCredentials( + Uri? url, + String? realm, + _i14.HttpClientCredentials? credentials, + ) => + super.noSuchMethod( + Invocation.method( + #addCredentials, + [ + url, + realm, + credentials, + ], + ), + returnValueForMissingStub: null, + ); + @override + void addProxyCredentials( + String? host, + int? port, + String? realm, + _i14.HttpClientCredentials? credentials, + ) => + super.noSuchMethod( + Invocation.method( + #addProxyCredentials, + [ + host, + port, + realm, + credentials, + ], + ), + returnValueForMissingStub: null, + ); + @override + void close({bool? force = false}) => super.noSuchMethod( + Invocation.method( + #close, + [], + {#force: force}, + ), + returnValueForMissingStub: null, + ); } /// A class which mocks [FakeFilePickerPlatform]. @@ -4097,7 +5482,7 @@ class MockDio extends _i1.Mock implements _i25.Dio { class MockFilePickerPlatform extends _i1.Mock implements _i27.FakeFilePickerPlatform { @override - _i16.Future<_i28.FilePickerResult?> pickFiles({ + _i17.Future<_i28.FilePickerResult?> pickFiles({ String? dialogTitle, String? initialDirectory, _i28.FileType? type = _i28.FileType.any, @@ -4126,20 +5511,20 @@ class MockFilePickerPlatform extends _i1.Mock #lockParentWindow: lockParentWindow, }, ), - returnValue: _i16.Future<_i28.FilePickerResult?>.value(), - returnValueForMissingStub: _i16.Future<_i28.FilePickerResult?>.value(), - ) as _i16.Future<_i28.FilePickerResult?>); + returnValue: _i17.Future<_i28.FilePickerResult?>.value(), + returnValueForMissingStub: _i17.Future<_i28.FilePickerResult?>.value(), + ) as _i17.Future<_i28.FilePickerResult?>); @override - _i16.Future clearTemporaryFiles() => (super.noSuchMethod( + _i17.Future clearTemporaryFiles() => (super.noSuchMethod( Invocation.method( #clearTemporaryFiles, [], ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future getDirectoryPath({ + _i17.Future getDirectoryPath({ String? dialogTitle, bool? lockParentWindow = false, String? initialDirectory, @@ -4154,11 +5539,11 @@ class MockFilePickerPlatform extends _i1.Mock #initialDirectory: initialDirectory, }, ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); @override - _i16.Future saveFile({ + _i17.Future saveFile({ String? dialogTitle, String? fileName, String? initialDirectory, @@ -4179,7 +5564,7 @@ class MockFilePickerPlatform extends _i1.Mock #lockParentWindow: lockParentWindow, }, ), - returnValue: _i16.Future.value(), - returnValueForMissingStub: _i16.Future.value(), - ) as _i16.Future); + returnValue: _i17.Future.value(), + returnValueForMissingStub: _i17.Future.value(), + ) as _i17.Future); } diff --git a/test/test_util/test_datas.dart b/test/test_util/test_datas.dart index d9f91fb84..6b823c22e 100644 --- a/test/test_util/test_datas.dart +++ b/test/test_util/test_datas.dart @@ -379,8 +379,6 @@ class TestData { } ''')); - static String note1ExpectText = "気づいたら、健康保険証っぽいプラズマ化したつまようじの賞味期限が切れてました…"; - static String note1ExpectId = "9g3rcngj3e"; static Note note2 = Note.fromJson(JSON5.parse(r''' { @@ -420,10 +418,6 @@ class TestData { } ''')); - /// 自身のノート(藍ちゃん)2 - static String note2ExpectText = - "みにゃさん、数取りゲームしましょう!\n0~100の中で最も大きい数字を取った人が勝ちです。他の人と被ったらだめですよ~\n制限時間は10分です。数字はこの投稿にリプライで送ってくださいね!"; - /// 自身でないノート1 static Note note3AsAnotherUser = Note.fromJson(JSON5.parse(r''' { @@ -650,8 +644,6 @@ class TestData { } ''')); - static String note3ExpectUserName = "@oishiibot"; - // ドライブ(フォルダ) static DriveFolder folder1 = DriveFolder.fromJson(JSON5.parse(r''' { @@ -1398,8 +1390,8 @@ class TestData { hasUnreadNote: false, } ''')); - static String channel1ExpectId = "9axtmmcxuy"; - static String channel1ExpectName = "ブルーアーカイ部 総合"; + + static String expectChannel1DescriptionContaining = "ありがとうブルーアーカイブ"; static CommunityChannel channel2 = CommunityChannel.fromJson(JSON5.parse(r''' { @@ -1422,8 +1414,270 @@ class TestData { hasUnreadNote: false, } ''')); - static String channel2ExpectId = "9b3chwrm7f"; - static String channel2ExpectName = "Misskeyアークナイツ部"; + + // アンテナ + static Antenna antenna = Antenna.fromJson(JSON5.parse(r''' +{ + id: '9f7kcbzcoe', + createdAt: '2023-05-26T03:24:02.856Z', + name: 'ポテイモン', + keywords: [ + [ + 'ポテイモン', + ], + [ + '芋神', + ], + [ + 'misscat', + ], + ], + excludeKeywords: [ + [ + '応天門', + ], + ], + src: 'all', + userListId: null, + users: [ + '', + ], + caseSensitive: false, + notify: false, + withReplies: false, + withFile: false, + isActive: true, + hasUnreadNote: false, + } +''')); + + static Clip clip = Clip.fromJson(JSON5.parse(r''' +{ + id: '9crm7l2n4k', + createdAt: '2023-03-25T14:12:37.103Z', + lastClippedAt: '2023-06-27T10:08:56.762Z', + userId: '9byjlos32z', + user: { + id: '7rkr3b1c1c', + name: '藍', + username: 'ai', + host: null, + avatarUrl: 'https://proxy.misskeyusercontent.com/avatar.webp?url=https%3A%2F%2Fs3.arkjp.net%2Fmisskey%2Fwebpublic-ecc1008f-3e2e-4206-ae7e-5093221f08be.png&avatar=1', + avatarBlurhash: null, + isBot: true, + isCat: true, + emojis: {}, + onlineStatus: 'online', + badgeRoles: [], + }, + name: 'ぴょんぷっぷー', + description: null, + isPublic: true, + favoritedCount: 0, + isFavorited: false, + } + +''')); + + static RolesListResponse role = RolesListResponse.fromJson(JSON5.parse(''' +{ + id: '9diazxez3m', + createdAt: '2023-04-13T06:28:30.827Z', + updatedAt: '2023-06-25T09:28:16.529Z', + name: 'Super New User', + description: 'アカウント作成してから1日以内のユーザー', + color: '#a4850a', + iconUrl: 'https://s3.arkjp.net/misskey/358069f4-e033-4366-891b-fcc4fc4d0c70.png', + target: 'conditional', + condFormula: { + id: '83328ff6-8bdc-4516-9dee-751222897481', + type: 'and', + values: [ + { + id: 'deac20b7-2688-4d7e-a264-5d0f0345f003', + type: 'isLocal', + }, + { + id: '9959c843-b273-4edf-8632-41b103af8b88', + sec: 86400, + type: 'createdLessThan', + }, + ], + }, + isPublic: true, + isAdministrator: false, + isModerator: false, + isExplorable: true, + asBadge: true, + canEditMembersByModerator: false, + displayOrder: 0, + policies: { + pinLimit: { + value: 3, + priority: 0, + useDefault: true, + }, + canInvite: { + value: false, + priority: 0, + useDefault: true, + }, + clipLimit: { + value: 10, + priority: 0, + useDefault: true, + }, + canHideAds: { + value: false, + priority: 0, + useDefault: true, + }, + antennaLimit: { + value: 5, + priority: 0, + useDefault: true, + }, + gtlAvailable: { + value: true, + priority: 0, + useDefault: true, + }, + ltlAvailable: { + value: true, + priority: 0, + useDefault: true, + }, + webhookLimit: { + value: 3, + priority: 0, + useDefault: true, + }, + canPublicNote: { + value: true, + priority: 0, + useDefault: true, + }, + userListLimit: { + value: 5, + priority: 0, + useDefault: true, + }, + wordMuteLimit: { + value: 200, + priority: 0, + useDefault: true, + }, + alwaysMarkNsfw: { + value: false, + priority: 0, + useDefault: true, + }, + canSearchNotes: { + value: false, + priority: 0, + useDefault: true, + }, + driveCapacityMb: { + value: 10240, + priority: 0, + useDefault: true, + }, + rateLimitFactor: { + value: 2, + priority: 0, + useDefault: true, + }, + noteEachClipsLimit: { + value: 50, + priority: 0, + useDefault: true, + }, + canManageCustomEmojis: { + value: false, + priority: 0, + useDefault: true, + }, + userEachUserListsLimit: { + value: 20, + priority: 0, + useDefault: true, + }, + canCreateContent: { + useDefault: true, + priority: 0, + value: true, + }, + canUpdateContent: { + useDefault: true, + priority: 0, + value: true, + }, + canDeleteContent: { + useDefault: true, + priority: 0, + value: true, + }, + inviteLimit: { + useDefault: true, + priority: 0, + value: 0, + }, + inviteLimitCycle: { + useDefault: true, + priority: 0, + value: 10080, + }, + inviteExpirationTime: { + useDefault: true, + priority: 0, + value: 0, + }, + }, + usersCount: 0, + } +''')); + + static HashtagsTrendResponse hashtagTrends = + HashtagsTrendResponse.fromJson(JSON5.parse(r''' +{ + tag: 'ろぐぼチャレンジ', + chart: [ + 3, + 2, + 2, + 1, + 3, + 4, + 2, + 4, + 2, + 4, + 0, + 0, + 3, + 2, + 3, + 6, + 5, + 4, + 12, + 8, + ], + usersCount: 15, + } +''')); + + static Hashtag hashtag = Hashtag.fromJson(JSON5.parse(r''' +{ + tag: 'アークナイツ', + mentionedUsersCount: 531, + mentionedLocalUsersCount: 3, + mentionedRemoteUsersCount: 528, + attachedUsersCount: 67, + attachedLocalUsersCount: 2, + attachedRemoteUsersCount: 65, + } +''')); // Dio static DioError response404 = DioError( diff --git a/test/view/antenna_list_page/antenna_list_page_test.dart b/test/view/antenna_list_page/antenna_list_page_test.dart new file mode 100644 index 000000000..88740ab9f --- /dev/null +++ b/test/view/antenna_list_page/antenna_list_page_test.dart @@ -0,0 +1,29 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("アンテナ一覧", () { + testWidgets("アンテナ一覧が表示されること", (tester) async { + final antennas = MockMisskeyAntenna(); + final misskey = MockMisskey(); + when(misskey.antennas).thenReturn(antennas); + when(antennas.list()).thenAnswer((_) async => [TestData.antenna]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: AntennaRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + expect(find.text(TestData.antenna.name), findsOneWidget); + }); + }); +} diff --git a/test/view/antenna_notes_page/antenna_notes_page_test.dart b/test/view/antenna_notes_page/antenna_notes_page_test.dart new file mode 100644 index 000000000..18dcd9354 --- /dev/null +++ b/test/view/antenna_notes_page/antenna_notes_page_test.dart @@ -0,0 +1,33 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:misskey_dart/misskey_dart.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("アンテナノート一覧", () { + testWidgets("アンテナのノート一覧が表示されること", (tester) async { + final antennas = MockMisskeyAntenna(); + final misskey = MockMisskey(); + when(misskey.antennas).thenReturn(antennas); + when(antennas.notes(any)).thenAnswer((_) async => [TestData.note1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: AntennaNotesRoute( + account: TestData.account, antenna: TestData.antenna), + ))); + await tester.pumpAndSettle(); + + expect(find.text(TestData.note1.text!), findsOneWidget); + verify(antennas.notes(argThat( + equals(AntennasNotesRequest(antennaId: TestData.antenna.id))))); + }); + }); +} diff --git a/test/view/channel_detail_page/channel_detail_page_test.dart b/test/view/channel_detail_page/channel_detail_page_test.dart new file mode 100644 index 000000000..ffb49d825 --- /dev/null +++ b/test/view/channel_detail_page/channel_detail_page_test.dart @@ -0,0 +1,172 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:misskey_dart/misskey_dart.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("チャンネル詳細", () { + testWidgets("チャンネルの詳細情報が表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)) + .thenAnswer((_) async => TestData.channel1.copyWith(bannerUrl: null)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + expect( + find.textContaining(TestData.expectChannel1DescriptionContaining, + findRichText: true), + findsOneWidget); + }); + + testWidgets("チャンネルがセンシティブの場合、センシティブである旨が表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isSensitive: true)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + expect(find.textContaining("センシティブ"), findsOneWidget); + }); + + testWidgets("チャンネルをお気に入りに設定していない場合、お気に入りにすることができること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isFavorited: false)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("お気に入りにいれる")); + await tester.pumpAndSettle(); + expect(find.text("お気に入り中"), findsOneWidget); + + verify(channel.favorite(argThat( + equals(ChannelsFavoriteRequest(channelId: TestData.channel1.id))))); + }); + + testWidgets("チャンネルをお気に入りに設定している場合、お気に入りを解除できること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isFavorited: true)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("お気に入り中")); + await tester.pumpAndSettle(); + expect(find.text("お気に入りにいれる"), findsOneWidget); + + verify(channel.unfavorite(argThat( + equals(ChannelsUnfavoriteRequest(channelId: TestData.channel1.id))))); + }); + + testWidgets("チャンネルをフォローしていない場合、フォローすることができること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isFollowing: false)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("フォローする")); + await tester.pumpAndSettle(); + expect(find.text("フォローしています"), findsOneWidget); + + verify(channel.follow(argThat( + equals(ChannelsFollowRequest(channelId: TestData.channel1.id))))); + }); + + testWidgets("チャンネルをフォローしている場合、フォロー解除をすることができること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isFollowing: true)); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("フォローしています")); + await tester.pumpAndSettle(); + expect(find.text("フォローする"), findsOneWidget); + + verify(channel.unfollow(argThat( + equals(ChannelsUnfollowRequest(channelId: TestData.channel1.id))))); + }); + }); + + group("チャンネル内ノート", () { + testWidgets("チャンネル内のノートが表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.show(any)).thenAnswer((_) async => + TestData.channel1.copyWith(bannerUrl: null, isFollowing: false)); + when(channel.timeline(any)) + .thenAnswer((realInvocation) async => [TestData.note1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelDetailRoute( + account: TestData.account, channelId: TestData.channel1.id), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("タイムライン")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.note1.text!), findsOneWidget); + verify(channel.timeline(argThat(predicate( + (e) => e.channelId == TestData.channel1.id)))); + }); + }); +} diff --git a/test/view/channel_page/channel_page_test.dart b/test/view/channel_page/channel_page_test.dart new file mode 100644 index 000000000..ef8df45ce --- /dev/null +++ b/test/view/channel_page/channel_page_test.dart @@ -0,0 +1,113 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:misskey_dart/misskey_dart.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("チャンネル", () { + group("チャンネル検索", () { + testWidgets("チャンネル検索ができること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.search(any)).thenAnswer( + (_) async => [TestData.channel1.copyWith(bannerUrl: null)]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelsRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("検索")); + await tester.pumpAndSettle(); + + await tester.enterText(find.byType(TextField), "ゲーム開発部"); + await tester.testTextInput.receiveAction(TextInputAction.done); + await tester.pumpAndSettle(); + + expect(find.text(TestData.channel1.name), findsOneWidget); + verify(channel.search( + argThat(equals(const ChannelsSearchRequest(query: "ゲーム開発部"))))); + }); + }); + + group("トレンド", () { + testWidgets("トレンドが表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.featured()).thenAnswer( + (_) async => [TestData.channel1.copyWith(bannerUrl: null)]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelsRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("トレンド")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.channel1.name), findsOneWidget); + }); + }); + + group("お気に入り", () { + testWidgets("お気に入り中のチャンネルが表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.myFavorite(any)).thenAnswer( + (_) async => [TestData.channel1.copyWith(bannerUrl: null)]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelsRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("お気に入り")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.channel1.name), findsOneWidget); + verify(channel + .myFavorite(argThat(equals(const ChannelsMyFavoriteRequest())))); + }); + }); + + group("フォロー中", () { + testWidgets("フォロー中のチャンネルが表示されること", (tester) async { + final channel = MockMisskeyChannels(); + final misskey = MockMisskey(); + when(misskey.channels).thenReturn(channel); + when(channel.followed(any)).thenAnswer( + (_) async => [TestData.channel1.copyWith(bannerUrl: null)]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ChannelsRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + await tester.tap(find.text("フォロー中")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.channel1.name), findsOneWidget); + verify( + channel.followed(argThat(equals(const ChannelsFollowedRequest())))); + }); + }); + }); +} diff --git a/test/view/clip_detail_page/clip_detail_page_test.dart b/test/view/clip_detail_page/clip_detail_page_test.dart new file mode 100644 index 000000000..6d71ddd78 --- /dev/null +++ b/test/view/clip_detail_page/clip_detail_page_test.dart @@ -0,0 +1,30 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("クリップのノート一覧", () { + testWidgets("クリップ済みノートが表示されること", (tester) async { + final clip = MockMisskeyClips(); + final misskey = MockMisskey(); + when(misskey.clips).thenReturn(clip); + when(clip.notes(any)).thenAnswer((_) async => [TestData.note1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ClipDetailRoute( + id: TestData.clip.id, account: TestData.account), + ))); + await tester.pumpAndSettle(); + + expect(find.text(TestData.note1.text!), findsOneWidget); + }); + }); +} diff --git a/test/view/clip_list_page/clip_list_page_test.dart b/test/view/clip_list_page/clip_list_page_test.dart new file mode 100644 index 000000000..32729c355 --- /dev/null +++ b/test/view/clip_list_page/clip_list_page_test.dart @@ -0,0 +1,29 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("クリップ一覧", () { + testWidgets("クリップ一覧が表示されること", (tester) async { + final clip = MockMisskeyClips(); + final misskey = MockMisskey(); + when(misskey.clips).thenReturn(clip); + when(clip.list()).thenAnswer((_) async => [TestData.clip]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ClipListRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + expect(find.text(TestData.clip.name!), findsOneWidget); + }); + }); +} diff --git a/test/view/explore_page/explore_page_test.dart b/test/view/explore_page/explore_page_test.dart new file mode 100644 index 000000000..0c29f579a --- /dev/null +++ b/test/view/explore_page/explore_page_test.dart @@ -0,0 +1,230 @@ +import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:flutter_test/flutter_test.dart'; +import 'package:miria/providers.dart'; +import 'package:miria/router/app_router.dart'; +import 'package:misskey_dart/misskey_dart.dart'; +import 'package:mockito/mockito.dart'; + +import '../../test_util/default_root_widget.dart'; +import '../../test_util/mock.mocks.dart'; +import '../../test_util/test_datas.dart'; + +void main() { + group("みつける", () { + group("ハイライト", () { + testWidgets("ハイライトのノートを表示できること", (tester) async { + final notes = MockMisskeyNotes(); + final misskey = MockMisskey(); + when(misskey.notes).thenReturn(notes); + when(notes.featured(any)).thenAnswer((_) async => [TestData.note1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + + expect(find.text(TestData.note1.text!), findsOneWidget); + verify(notes.featured(argThat(equals(const NotesFeaturedRequest())))); + }); + + testWidgets("アンケートのノートを表示できること", (tester) async { + final polls = MockMisskeyNotesPolls(); + final notes = MockMisskeyNotes(); + final misskey = MockMisskey(); + when(misskey.notes).thenReturn(notes); + when(notes.polls).thenReturn(polls); + when(polls.recommendation(any)) + .thenAnswer((_) async => [TestData.note1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("アンケート")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.note1.text!), findsOneWidget); + verify(polls.recommendation( + argThat(equals(const NotesPollsRecommendationRequest())))); + }); + }); + + group("ユーザー", () { + testWidgets("ピン留めされたユーザーを表示できること", (tester) async { + final misskey = MockMisskey(); + final notes = MockMisskeyNotes(); + when(misskey.notes).thenReturn(notes); + when(misskey.pinnedUsers()) + .thenAnswer((_) async => [TestData.detailedUser1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ユーザー")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.detailedUser1.name!), findsOneWidget); + }); + + testWidgets("ローカルのユーザーを表示できること", (tester) async { + final misskey = MockMisskey(); + final notes = MockMisskeyNotes(); + final users = MockMisskeyUsers(); + when(misskey.notes).thenReturn(notes); + when(misskey.users).thenReturn(users); + when(users.users(any)) + .thenAnswer((_) async => [TestData.detailedUser1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ユーザー")); + await tester.pumpAndSettle(); + await tester.tap(find.text("ローカル")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.detailedUser1.name!), findsOneWidget); + verify(users.users(argThat(equals(const UsersUsersRequest( + state: UsersState.alive, + origin: Origin.local, + sort: UsersSortType.followerDescendant))))); + }); + + testWidgets("リモートのユーザーを表示できること", (tester) async { + final misskey = MockMisskey(); + final notes = MockMisskeyNotes(); + final users = MockMisskeyUsers(); + when(misskey.notes).thenReturn(notes); + when(misskey.users).thenReturn(users); + when(users.users(any)) + .thenAnswer((_) async => [TestData.detailedUser1]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ユーザー")); + await tester.pumpAndSettle(); + await tester.tap(find.text("リモート")); + await tester.pumpAndSettle(); + + expect(find.text(TestData.detailedUser1.name!), findsOneWidget); + verify(users.users(argThat(equals(const UsersUsersRequest( + state: UsersState.alive, + origin: Origin.remote, + sort: UsersSortType.followerDescendant))))); + }); + }); + + group("ロール", () { + testWidgets("公開ロールを表示できること", (tester) async { + final misskey = MockMisskey(); + final roles = MockMisskeyRoles(); + when(misskey.roles).thenReturn(roles); + when(misskey.notes).thenReturn(MockMisskeyNotes()); + when(roles.list()) + .thenAnswer((_) async => [TestData.role.copyWith(usersCount: 495)]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ロール")); + await tester.pumpAndSettle(); + + expect(find.textContaining(TestData.role.name, findRichText: true), + findsOneWidget); + }); + }); + + group("ハッシュタグ", () { + testWidgets("トレンドのハッシュタグを表示できること", (tester) async { + final misskey = MockMisskey(); + final hashtags = MockMisskeyHashtags(); + when(misskey.hashtags).thenReturn(hashtags); + when(misskey.notes).thenReturn(MockMisskeyNotes()); + when(hashtags.trend()) + .thenAnswer((_) async => [TestData.hashtagTrends]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ハッシュタグ")); + await tester.pumpAndSettle(); + + expect(find.textContaining(TestData.hashtagTrends.tag), findsOneWidget); + }); + + testWidgets("ローカルのハッシュタグを表示できること", (tester) async { + final misskey = MockMisskey(); + final hashtags = MockMisskeyHashtags(); + when(misskey.hashtags).thenReturn(hashtags); + when(misskey.notes).thenReturn(MockMisskeyNotes()); + when(hashtags.list(any)).thenAnswer((_) async => [TestData.hashtag]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ハッシュタグ")); + await tester.pumpAndSettle(); + await tester.tap(find.text("ローカル")); + await tester.pumpAndSettle(); + + expect(find.textContaining(TestData.hashtag.tag), findsOneWidget); + + verify(hashtags.list(argThat(predicate((request) => + request.attachedToLocalUserOnly == true && + request.sort == + HashtagsListSortType.attachedLocalUsersDescendant)))); + }); + + testWidgets("リモートのハッシュタグを表示できること", (tester) async { + final misskey = MockMisskey(); + final hashtags = MockMisskeyHashtags(); + when(misskey.hashtags).thenReturn(hashtags); + when(misskey.notes).thenReturn(MockMisskeyNotes()); + when(hashtags.list(any)).thenAnswer((_) async => [TestData.hashtag]); + + await tester.pumpWidget(ProviderScope( + overrides: [misskeyProvider.overrideWith((_, __) => misskey)], + child: DefaultRootWidget( + initialRoute: ExploreRoute(account: TestData.account), + ))); + await tester.pumpAndSettle(); + await tester.tap(find.text("ハッシュタグ")); + await tester.pumpAndSettle(); + await tester.tap(find.text("リモート")); + await tester.pumpAndSettle(); + + expect(find.textContaining(TestData.hashtag.tag), findsOneWidget); + + verify(hashtags.list(argThat(predicate((request) => + request.attachedToRemoteUserOnly == true && + request.sort == + HashtagsListSortType.attachedRemoteUsersDescendant)))); + }); + }); + + group("よそのサーバー", () {}); + }); +} diff --git a/test/view/note_create_page/note_create_page_test.dart b/test/view/note_create_page/note_create_page_test.dart index c1575f968..3bb268d8b 100644 --- a/test/view/note_create_page/note_create_page_test.dart +++ b/test/view/note_create_page/note_create_page_test.dart @@ -48,7 +48,7 @@ void main() { ))); await tester.pumpAndSettle(); - expect(find.text(TestData.channel1ExpectName), findsOneWidget); + expect(find.text(TestData.channel1.name), findsOneWidget); await tester.enterText( find.byType(TextField).hitTestable(), ":ai_yay:"); @@ -56,7 +56,7 @@ void main() { await tester.pumpAndSettle(); verify(mockNote.create(argThat(equals(predicate( - (arg) => arg.channelId == TestData.channel1ExpectId))))); + (arg) => arg.channelId == TestData.channel1.id))))); }); testWidgets("削除されたノートを直す場合で、そのノートがチャンネルのノートの場合、チャンネルのノートになること", @@ -80,7 +80,7 @@ void main() { ))); await tester.pumpAndSettle(); - expect(find.text(TestData.channel1ExpectName), findsOneWidget); + expect(find.text(TestData.channel1.name), findsOneWidget); await tester.enterText( find.byType(TextField).hitTestable(), ":ai_yay:"); @@ -88,7 +88,7 @@ void main() { await tester.pumpAndSettle(); verify(mockNote.create(argThat(equals(predicate( - (arg) => arg.channelId == TestData.channel1ExpectId))))); + (arg) => arg.channelId == TestData.channel1.id))))); }); testWidgets("チャンネルのノートにリプライをする場合、そのノートもチャンネルのノートになること", (tester) async { @@ -111,7 +111,7 @@ void main() { ))); await tester.pumpAndSettle(); - expect(find.text(TestData.channel1ExpectName), findsOneWidget); + expect(find.text(TestData.channel1.name), findsOneWidget); await tester.enterText( find.byType(TextField).hitTestable(), ":ai_yay:"); @@ -119,7 +119,7 @@ void main() { await tester.pumpAndSettle(); verify(mockNote.create(argThat(equals(predicate( - (arg) => arg.channelId == TestData.channel1ExpectId))))); + (arg) => arg.channelId == TestData.channel1.id))))); }); testWidgets("チャンネルのノートに引用リノートをする場合、引数のチャンネル先が選択されること", (tester) async { @@ -143,7 +143,7 @@ void main() { ))); await tester.pumpAndSettle(); - expect(find.text(TestData.channel2ExpectName), findsOneWidget); + expect(find.text(TestData.channel2.name), findsOneWidget); await tester.enterText( find.byType(TextField).hitTestable(), ":ai_yay:"); @@ -151,7 +151,7 @@ void main() { await tester.pumpAndSettle(); verify(mockNote.create(argThat(equals(predicate( - (arg) => arg.channelId == TestData.channel2ExpectId))))); + (arg) => arg.channelId == TestData.channel2.id))))); }); }); @@ -894,7 +894,8 @@ void main() { expect( find.descendant( of: find.byType(ReplyToArea), - matching: find.text(TestData.note3ExpectUserName, + matching: find.textContaining( + TestData.note3AsAnotherUser.user.username, findRichText: true)), findsOneWidget); }); @@ -1412,7 +1413,7 @@ void main() { find.descendant( of: find.byType(MfmPreview), matching: find.textContaining( - TestData.note3ExpectUserName.tight, + TestData.note3AsAnotherUser.user.username.tight, findRichText: true)), findsOneWidget); }); diff --git a/test/view/search_page/search_page_test.dart b/test/view/search_page/search_page_test.dart index 5e0260c51..4ed6fd98f 100644 --- a/test/view/search_page/search_page_test.dart +++ b/test/view/search_page/search_page_test.dart @@ -35,16 +35,16 @@ void main() { verify(mockNote.search( argThat(equals(const NotesSearchRequest(query: "Misskey"))))) .called(1); - expect(find.text(TestData.note1ExpectText), findsOneWidget); + expect(find.text(TestData.note1.text!), findsOneWidget); when(mockNote.search(any)).thenAnswer((_) async => [TestData.note2]); await tester.tap(find.byIcon(Icons.keyboard_arrow_down).at(1)); await tester.pumpAndSettle(); verify(mockNote.search(argThat(equals(NotesSearchRequest( - query: "Misskey", untilId: TestData.note1ExpectId))))) + query: "Misskey", untilId: TestData.note1.id))))) .called(1); - expect(find.text(TestData.note2ExpectText), findsOneWidget); + expect(find.text(TestData.note2.text!), findsOneWidget); }); testWidgets("ユーザー指定ができること", (tester) async { @@ -82,7 +82,7 @@ void main() { findsOneWidget); // ノートが表示されていること - expect(find.text(TestData.note1ExpectText), findsOneWidget); + expect(find.text(TestData.note1.text!), findsOneWidget); verify(mockNote.search(argThat(equals( NotesSearchRequest(query: "", userId: TestData.user1ExpectId))))) .called(1); @@ -114,20 +114,20 @@ void main() { await tester.tap(find.byIcon(Icons.keyboard_arrow_right).at(1)); await tester.pumpAndSettle(); - await tester.tap(find.text(TestData.channel1ExpectName)); + await tester.tap(find.text(TestData.channel1.name)); await tester.pumpAndSettle(); // 指定したユーザーが表示されていること expect( find.descendant( of: find.byType(Card), - matching: find.text(TestData.channel1ExpectName)), + matching: find.text(TestData.channel1.name)), findsOneWidget); // ノートが表示されていること - expect(find.text(TestData.note1ExpectText), findsOneWidget); - verify(mockNote.search(argThat(equals(NotesSearchRequest( - query: "", channelId: TestData.channel1ExpectId))))) + expect(find.text(TestData.note1.text!), findsOneWidget); + verify(mockNote.search(argThat(equals( + NotesSearchRequest(query: "", channelId: TestData.channel1.id))))) .called(1); }); @@ -152,16 +152,16 @@ void main() { verify(mockNote.searchByTag(argThat( equals(const NotesSearchByTagRequest(tag: "藍ちゃん大食いチャレンジ"))))) .called(1); - expect(find.text(TestData.note1ExpectText), findsOneWidget); + expect(find.text(TestData.note1.text!), findsOneWidget); when(mockNote.searchByTag(any)).thenAnswer((_) async => [TestData.note2]); await tester.tap(find.byIcon(Icons.keyboard_arrow_down).at(1)); await tester.pumpAndSettle(); verify(mockNote.searchByTag(argThat(equals(NotesSearchByTagRequest( - tag: "藍ちゃん大食いチャレンジ", untilId: TestData.note1ExpectId))))) + tag: "藍ちゃん大食いチャレンジ", untilId: TestData.note1.id))))) .called(1); - expect(find.text(TestData.note2ExpectText), findsOneWidget); + expect(find.text(TestData.note2.text!), findsOneWidget); }); }); @@ -302,7 +302,7 @@ void main() { )); await tester.pumpAndSettle(); - expect(find.text(TestData.note1ExpectText), findsOneWidget); + expect(find.text(TestData.note1.text!), findsOneWidget); verify(mockNote.search( argThat(equals(const NotesSearchRequest(query: "Misskey"))))) .called(1);