refactor(empty-state): 空状态支持内容居中
This commit is contained in:
1 parent
59fbd33059
commit
7463d3ee26
8 files changed
+131
-80
No files matched your search
@@ -174,6 +174,14 @@ void main() {
|
||||
|
||||
expect(find.byKey(const Key('favorites-empty')), findsOneWidget);
|
||||
expect(find.byType(EmptyState), findsOneWidget);
|
||||
final viewport = tester.getRect(
|
||||
find.byKey(const Key('favorites-empty-scroll')),
|
||||
);
|
||||
final content = tester.getRect(
|
||||
find.byKey(const Key('empty-state-content')),
|
||||
);
|
||||
expect(content.center.dx, closeTo(viewport.center.dx, 0.1));
|
||||
expect(content.center.dy, closeTo(viewport.center.dy, 0.1));
|
||||
});
|
||||
|
||||
testWidgets('should_show_retry_when_favorite_list_fails', (tester) async {
|
||||
|
||||
Reference in new issue
Block a user