feat(app): 剧场页九宫格与极简我的页
This commit is contained in:
1 parent
dc8ca7b743
commit
35338cbfc8
46 files changed
+2353
-4358
No files matched your search
+13
-35
@@ -150,7 +150,6 @@ void main() {
|
||||
isFalse,
|
||||
);
|
||||
expect(find.text('Quick access'), findsOneWidget);
|
||||
expect(find.text('Bahasa Indonesia'), findsOneWidget);
|
||||
expect(find.text('7 EPISODES'), findsOneWidget);
|
||||
expect(tester.takeException(), isNull);
|
||||
|
||||
@@ -181,7 +180,7 @@ void main() {
|
||||
},
|
||||
);
|
||||
|
||||
testWidgets('should_change_interface_language_when_locale_is_picked', (
|
||||
testWidgets('should_follow_system_locale_without_language_switch', (
|
||||
tester,
|
||||
) async {
|
||||
tester.view.physicalSize = const Size(390, 844);
|
||||
@@ -196,20 +195,13 @@ void main() {
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('Vicky sheng'), findsOneWidget);
|
||||
expect(find.text('Coins'), findsOneWidget);
|
||||
await tester.drag(find.byType(ListView), const Offset(0, -700));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.text('App Language'));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.text('简体中文').last);
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('我的'), findsWidgets);
|
||||
await tester.drag(find.byType(ListView), const Offset(0, 700));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('App Language'), findsNothing);
|
||||
expect(find.text('简体中文'), findsNothing);
|
||||
expect(find.byKey(const Key('mine-wallet')), findsOneWidget);
|
||||
expect(find.text('首页'), findsOneWidget);
|
||||
await tester.tap(find.text('发现'));
|
||||
expect(find.text('Home'), findsWidgets);
|
||||
await tester.tap(find.byKey(const Key('tab-discover')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('推荐'), findsOneWidget);
|
||||
expect(find.text('Discover'), findsWidgets);
|
||||
});
|
||||
|
||||
testWidgets(
|
||||
@@ -297,7 +289,8 @@ void main() {
|
||||
await tester.tap(find.byKey(const Key('tab-discover')));
|
||||
await tester.pumpAndSettle();
|
||||
|
||||
expect(find.text('Recommended'), findsOneWidget);
|
||||
expect(find.byKey(const Key('discover-category-grid')), findsOneWidget);
|
||||
expect(find.byKey(const Key('discover-ranking-section')), findsOneWidget);
|
||||
expect(find.byKey(const Key('home-all-dramas-grid')), findsOneWidget);
|
||||
expect(find.byKey(const Key('discover-profile')), findsOneWidget);
|
||||
expect(
|
||||
@@ -319,11 +312,7 @@ void main() {
|
||||
|
||||
await tester.tap(find.byKey(const Key('tab-my')));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.drag(find.byType(ListView), const Offset(0, -320));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.byKey(const Key('mine-library-tab-1')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('No shows here yet.'), findsOneWidget);
|
||||
expect(find.byKey(const Key('mine-menu')), findsOneWidget);
|
||||
await tester.tap(find.byKey(const Key('tab-home')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('The Signal'), findsOneWidget);
|
||||
@@ -353,16 +342,11 @@ void main() {
|
||||
|
||||
await tester.tap(find.byKey(const Key('tab-my')));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.drag(find.byType(ListView), const Offset(0, -700));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('History'), findsWidgets);
|
||||
expect(find.byKey(const Key('mine-history')), findsOneWidget);
|
||||
expect(
|
||||
Navigator.of(tester.element(find.text('History').first)).canPop(),
|
||||
Navigator.of(tester.element(find.byKey(const Key('mine-menu')))).canPop(),
|
||||
isFalse,
|
||||
);
|
||||
await tester.tap(find.byKey(const Key('mine-library-tab-1')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('No shows here yet.'), findsOneWidget);
|
||||
|
||||
await tester.tap(find.byKey(const Key('tab-discover')));
|
||||
await tester.pumpAndSettle();
|
||||
@@ -376,11 +360,7 @@ void main() {
|
||||
);
|
||||
await tester.tap(find.byKey(const Key('tab-my')));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.drag(find.byType(ListView), const Offset(0, -400));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.byKey(const Key('mine-library-tab-1')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('No shows here yet.'), findsOneWidget);
|
||||
expect(find.byKey(const Key('mine-menu')), findsOneWidget);
|
||||
await tester.tap(find.byKey(const Key('tab-home')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('The Signal'), findsOneWidget);
|
||||
@@ -625,9 +605,7 @@ void main() {
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.byKey(const Key('tab-my')));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.drag(find.byType(ListView), const Offset(0, -320));
|
||||
await tester.pumpAndSettle();
|
||||
await tester.tap(find.byKey(const Key('mine-library-tab-1')));
|
||||
await tester.tap(find.byKey(const Key('mine-watchlist')));
|
||||
await tester.pumpAndSettle();
|
||||
expect(find.text('The Signal'), findsOneWidget);
|
||||
expect(find.text('City Lights & Velvet Nights'), findsWidgets);
|
||||
|
||||
Reference in new issue
Block a user