mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Make sure that a CupertinoLinearActivityIndicator doesn't crash in 0x… (#178566)
This is my attempt to handle https://github.com/flutter/flutter/issues/6537 for the CupertinoLinearActivityIndicator widget. Co-authored-by: Tong Mu <dkwingsmt@users.noreply.github.com> Co-authored-by: Victor Sanni <victorsanniay@gmail.com>
This commit is contained in:
parent
946edbc5f9
commit
3ff025970a
@ -213,6 +213,19 @@ void main() {
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
testWidgets('CupertinoLinearActivityIndicator does not crash at zero area', (
|
||||
WidgetTester tester,
|
||||
) async {
|
||||
await tester.pumpWidget(
|
||||
const CupertinoApp(
|
||||
home: Center(
|
||||
child: SizedBox.shrink(child: CupertinoLinearActivityIndicator(progress: 0.5)),
|
||||
),
|
||||
),
|
||||
);
|
||||
expect(tester.getSize(find.byType(CupertinoLinearActivityIndicator)), Size.zero);
|
||||
});
|
||||
}
|
||||
|
||||
Widget buildCupertinoActivityIndicator([bool? animating]) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user