@@ -57,7 +57,7 @@ RenderParagraph _getTextRenderObjectFromDialog(WidgetTester tester, String text)
57
57
// What was the AlertDialog's ButtonBar when many of these tests were written,
58
58
// is now a Padding widget with an OverflowBar child. The Padding widget's size
59
59
// and location match the original ButtonBar's size and location.
60
- Finder _findButtonBar () {
60
+ Finder _findOverflowBar () {
61
61
return find.ancestor (of: find.byType (OverflowBar ), matching: find.byType (Padding )).first;
62
62
}
63
63
@@ -610,7 +610,7 @@ void main() {
610
610
matching: find.byType (Material ),
611
611
).first,
612
612
);
613
- final Size actionsSize = tester.getSize (_findButtonBar ());
613
+ final Size actionsSize = tester.getSize (_findOverflowBar ());
614
614
615
615
expect (actionsSize.width, dialogSize.width);
616
616
});
@@ -687,25 +687,25 @@ void main() {
687
687
// First button
688
688
expect (
689
689
tester.getTopRight (find.byKey (key1)).dy,
690
- tester.getTopRight (_findButtonBar ()).dy + 8.0 ,
690
+ tester.getTopRight (_findOverflowBar ()).dy + 8.0 ,
691
691
); // top
692
692
expect (
693
693
tester.getBottomRight (find.byKey (key1)).dy,
694
- tester.getBottomRight (_findButtonBar ()).dy - 8.0 ,
694
+ tester.getBottomRight (_findOverflowBar ()).dy - 8.0 ,
695
695
); // bottom
696
696
697
697
// Second button
698
698
expect (
699
699
tester.getTopRight (find.byKey (key2)).dy,
700
- tester.getTopRight (_findButtonBar ()).dy + 8.0 ,
700
+ tester.getTopRight (_findOverflowBar ()).dy + 8.0 ,
701
701
); // top
702
702
expect (
703
703
tester.getBottomRight (find.byKey (key2)).dy,
704
- tester.getBottomRight (_findButtonBar ()).dy - 8.0 ,
704
+ tester.getBottomRight (_findOverflowBar ()).dy - 8.0 ,
705
705
); // bottom
706
706
expect (
707
707
tester.getBottomRight (find.byKey (key2)).dx,
708
- tester.getBottomRight (_findButtonBar ()).dx - 8.0 ,
708
+ tester.getBottomRight (_findOverflowBar ()).dx - 8.0 ,
709
709
); // right
710
710
});
711
711
@@ -745,25 +745,25 @@ void main() {
745
745
// First button
746
746
expect (
747
747
tester.getTopRight (find.byKey (key1)).dy,
748
- tester.getTopRight (_findButtonBar ()).dy,
748
+ tester.getTopRight (_findOverflowBar ()).dy,
749
749
); // top
750
750
expect (
751
751
tester.getBottomRight (find.byKey (key1)).dy,
752
- tester.getBottomRight (_findButtonBar ()).dy - 24.0 ,
752
+ tester.getBottomRight (_findOverflowBar ()).dy - 24.0 ,
753
753
); // bottom
754
754
755
755
// // Second button
756
756
expect (
757
757
tester.getTopRight (find.byKey (key2)).dy,
758
- tester.getTopRight (_findButtonBar ()).dy,
758
+ tester.getTopRight (_findOverflowBar ()).dy,
759
759
); // top
760
760
expect (
761
761
tester.getBottomRight (find.byKey (key2)).dy,
762
- tester.getBottomRight (_findButtonBar ()).dy - 24.0 ,
762
+ tester.getBottomRight (_findOverflowBar ()).dy - 24.0 ,
763
763
); // bottom
764
764
expect (
765
765
tester.getBottomRight (find.byKey (key2)).dx,
766
- tester.getBottomRight (_findButtonBar ()).dx - 24.0 ,
766
+ tester.getBottomRight (_findOverflowBar ()).dx - 24.0 ,
767
767
); // right
768
768
});
769
769
@@ -809,25 +809,25 @@ void main() {
809
809
// First button
810
810
expect (
811
811
tester.getTopRight (find.byKey (key1)).dy,
812
- tester.getTopRight (_findButtonBar ()).dy + ((10.0 + 20.0 ) / 2 ),
812
+ tester.getTopRight (_findOverflowBar ()).dy + ((10.0 + 20.0 ) / 2 ),
813
813
); // top
814
814
expect (
815
815
tester.getBottomRight (find.byKey (key1)).dy,
816
- tester.getBottomRight (_findButtonBar ()).dy - ((10.0 + 20.0 ) / 2 ),
816
+ tester.getBottomRight (_findOverflowBar ()).dy - ((10.0 + 20.0 ) / 2 ),
817
817
); // bottom
818
818
819
819
// Second button
820
820
expect (
821
821
tester.getTopRight (find.byKey (key2)).dy,
822
- tester.getTopRight (_findButtonBar ()).dy + ((10.0 + 20.0 ) / 2 ),
822
+ tester.getTopRight (_findOverflowBar ()).dy + ((10.0 + 20.0 ) / 2 ),
823
823
); // top
824
824
expect (
825
825
tester.getBottomRight (find.byKey (key2)).dy,
826
- tester.getBottomRight (_findButtonBar ()).dy - ((10.0 + 20.0 ) / 2 ),
826
+ tester.getBottomRight (_findOverflowBar ()).dy - ((10.0 + 20.0 ) / 2 ),
827
827
); // bottom
828
828
expect (
829
829
tester.getBottomRight (find.byKey (key2)).dx,
830
- tester.getBottomRight (_findButtonBar ()).dx - ((10.0 + 20.0 ) / 2 ),
830
+ tester.getBottomRight (_findOverflowBar ()).dx - ((10.0 + 20.0 ) / 2 ),
831
831
); // right
832
832
});
833
833
@@ -850,7 +850,7 @@ void main() {
850
850
final Finder iconFinder = find.byKey (iconKey);
851
851
final Finder titleFinder = find.byKey (titleKey);
852
852
final Finder contentFinder = find.byKey (contentKey);
853
- final Finder actionsFinder = _findButtonBar ();
853
+ final Finder actionsFinder = _findOverflowBar ();
854
854
final Finder childrenFinder = find.byKey (childrenKey);
855
855
856
856
Future <void > openDialog (WidgetTester tester, Widget dialog, double textScaleFactor, {bool isM3 = false }) async {
0 commit comments