fix(recommend): 修正进度拖动与底栏联动

This commit is contained in:
Zhou Weidong committed 2026-10-22 20:15:07 +08:00
1 parent afe7a49ef0
commit 2765343340
9 files changed
+79 -107

No files matched your search

+9 -5
View File
@@ -102,15 +102,19 @@ void main() {
await tester.pump(const Duration(milliseconds: 130));
expect(find.byKey(const Key('recommend-top-nav')), findsOneWidget);
expect(tester.getCenter(progress).dy, closeTo(progressCenterY, 0.1));
final navVisibility = find.ancestor(
of: find.byKey(const Key('home-tabs-bar')),
matching: find.byType(Visibility),
expect(find.byType(AppBottomNav), findsOneWidget);
expect(
tester.getSize(find.byKey(const Key('home-tabs-bar'))).height,
AppDimens.navHeight,
);
expect(tester.widget<Visibility>(navVisibility.first).visible, isFalse);
await scrub.up();
await tester.pumpAndSettle();
expect(find.byKey(const Key('recommend-top-nav')), findsOneWidget);
expect(tester.widget<Visibility>(navVisibility.first).visible, isTrue);
expect(find.byType(AppBottomNav), findsOneWidget);
expect(
tester.getSize(find.byKey(const Key('home-tabs-bar'))).height,
AppDimens.navHeight,
);
await tester.tap(find.byKey(const Key('recommend-tab-playlist')));
await tester.pumpAndSettle();