feat: Implement comprehensive navigation logic for various notification types within the NotificationWidget.

This commit is contained in:
mso7nueh
2026-02-12 11:25:06 +03:00
committed by misha
parent b7804db49d
commit bb97c395dd
16 changed files with 1211 additions and 106 deletions

View File

@@ -101,7 +101,7 @@ void main() {
registerMocks(cubit, commentsCubit);
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false)));
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false, highlightedCommentId: null)));
await tester.pump();
expect(find.byType(AboutDietScreen), findsOneWidget);
@@ -127,7 +127,7 @@ void main() {
registerMocks(cubit, commentsCubit);
await mockNetworkImagesFor(() async {
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false)));
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false, highlightedCommentId: null)));
await tester.pump();
await tester.pump(const Duration(milliseconds: 600));
});
@@ -157,7 +157,7 @@ void main() {
registerMocks(cubit, commentsCubit);
await mockNetworkImagesFor(() async {
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false)));
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false, highlightedCommentId: null)));
await tester.pump();
await tester.pump(const Duration(milliseconds: 600));
});
@@ -183,7 +183,7 @@ void main() {
registerMocks(cubit, commentsCubit);
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false)));
await tester.pumpWidget(wrap(cubit, feedCubit, commentsCubit, const AboutDietScreen(slug: 'test', id: null, index: null, navigateToComments: false, highlightedCommentId: null)));
await tester.pump();
expect(find.byType(AboutDietScreen), findsOneWidget);