fix(recommend): 修正推荐子页内容映射
This commit is contained in:
1 parent
af6b9bb3db
commit
d06967c6ab
8 files changed
+128
-48
No files matched your search
@@ -70,7 +70,7 @@ void main() {
|
||||
expect(tester.getRect(grid), before);
|
||||
});
|
||||
|
||||
testWidgets('should_render_recommend_sections_and_inner_top_nav', (
|
||||
testWidgets('should_render_recommend_immersive_player_and_inner_top_nav', (
|
||||
tester,
|
||||
) async {
|
||||
await _pumpApp(tester);
|
||||
@@ -81,6 +81,10 @@ void main() {
|
||||
expect(find.byKey(const Key('recommend-tab-recommend')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-tab-playlist')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-tab-all')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-feed-player')), findsOneWidget);
|
||||
|
||||
await tester.tap(find.byKey(const Key('recommend-tab-playlist')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.byKey(const Key('recommend-section-hits')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-section-new')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-section-costume')), findsOneWidget);
|
||||
@@ -95,7 +99,7 @@ void main() {
|
||||
|
||||
await tester.tap(find.byKey(const Key('recommend-tab-playlist')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.byKey(const Key('ranking-page')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-section-hits')), findsOneWidget);
|
||||
expect(find.byType(AppBottomNav), findsOneWidget);
|
||||
|
||||
await tester.tap(find.byKey(const Key('recommend-tab-all')));
|
||||
@@ -143,7 +147,7 @@ void main() {
|
||||
|
||||
await tester.tap(find.byKey(const Key('tab-recommend')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.byKey(const Key('recommend-section-hits')), findsOneWidget);
|
||||
expect(find.byKey(const Key('recommend-feed-player')), findsOneWidget);
|
||||
expect(tester.takeException(), isNull);
|
||||
});
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user