44
55import 'package:flutter/widgets.dart' ;
66import 'package:flutter_test/flutter_test.dart' ;
7+ import 'package:leak_tracker_flutter_testing/leak_tracker_flutter_testing.dart' ;
78
89void main () {
9- testWidgets ('OverflowBar documented defaults' , (WidgetTester tester) async {
10+ testWidgetsWithLeakTracking ('OverflowBar documented defaults' , (WidgetTester tester) async {
1011 const OverflowBar bar = OverflowBar ();
1112 expect (bar.spacing, 0 );
1213 expect (bar.alignment, null );
@@ -17,7 +18,7 @@ void main() {
1718 expect (bar.children, const < Widget > []);
1819 });
1920
20- testWidgets ('Empty OverflowBar' , (WidgetTester tester) async {
21+ testWidgetsWithLeakTracking ('Empty OverflowBar' , (WidgetTester tester) async {
2122 const Size size = Size (16 , 24 );
2223
2324 await tester.pumpWidget (
@@ -46,7 +47,7 @@ void main() {
4647 expect (tester.getSize (find.byType (OverflowBar )), Size .zero);
4748 });
4849
49- testWidgets ('OverflowBar horizontal layout' , (WidgetTester tester) async {
50+ testWidgetsWithLeakTracking ('OverflowBar horizontal layout' , (WidgetTester tester) async {
5051 final Key child1Key = UniqueKey ();
5152 final Key child2Key = UniqueKey ();
5253 final Key child3Key = UniqueKey ();
@@ -93,7 +94,7 @@ void main() {
9394 expect (tester.getRect (find.byKey (child1Key)), const Rect .fromLTRB (10.0 + 96 + 10.0 , 8 , 10.0 + 10.0 + 144 , 56 ));
9495 });
9596
96- testWidgets ('OverflowBar vertical layout' , (WidgetTester tester) async {
97+ testWidgetsWithLeakTracking ('OverflowBar vertical layout' , (WidgetTester tester) async {
9798 final Key child1Key = UniqueKey ();
9899 final Key child2Key = UniqueKey ();
99100 final Key child3Key = UniqueKey ();
@@ -174,7 +175,7 @@ void main() {
174175 expect (tester.getRect (find.byKey (child3Key)), const Rect .fromLTRB (100.0 / 2.0 - 32 / 2 , 112 , 100.0 / 2.0 + 32 / 2 , 144 ));
175176 });
176177
177- testWidgets ('OverflowBar intrinsic width' , (WidgetTester tester) async {
178+ testWidgetsWithLeakTracking ('OverflowBar intrinsic width' , (WidgetTester tester) async {
178179 Widget buildFrame ({ required double width }) {
179180 return Directionality (
180181 textDirection: TextDirection .ltr,
@@ -205,7 +206,7 @@ void main() {
205206 expect (tester.getSize (find.byType (OverflowBar )).width, 150 );
206207 });
207208
208- testWidgets ('OverflowBar intrinsic height' , (WidgetTester tester) async {
209+ testWidgetsWithLeakTracking ('OverflowBar intrinsic height' , (WidgetTester tester) async {
209210 Widget buildFrame ({ required double maxWidth }) {
210211 return Directionality (
211212 textDirection: TextDirection .ltr,
@@ -237,7 +238,7 @@ void main() {
237238 });
238239
239240
240- testWidgets ('OverflowBar is wider that its intrinsic width' , (WidgetTester tester) async {
241+ testWidgetsWithLeakTracking ('OverflowBar is wider that its intrinsic width' , (WidgetTester tester) async {
241242 final Key key0 = UniqueKey ();
242243 final Key key1 = UniqueKey ();
243244 final Key key2 = UniqueKey ();
@@ -273,7 +274,7 @@ void main() {
273274 expect (tester.getTopLeft (find.byKey (key2)).dx, 600 );
274275 });
275276
276- testWidgets ('OverflowBar with alignment should match Row with mainAxisAlignment' , (WidgetTester tester) async {
277+ testWidgetsWithLeakTracking ('OverflowBar with alignment should match Row with mainAxisAlignment' , (WidgetTester tester) async {
277278 final Key key0 = UniqueKey ();
278279 final Key key1 = UniqueKey ();
279280 final Key key2 = UniqueKey ();
0 commit comments