@@ -517,6 +517,23 @@ void main() {
517517 await tester.pumpAndSettle ();
518518 expect (find.byKey (const Key ('Breakpoints.smallMobile' )), findsOneWidget);
519519 expect (find.byKey (const Key ('Breakpoints.mediumMobile' )), findsNothing);
520+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
521+ expect (find.byKey (const Key ('Breakpoints.smallDesktop' )), findsNothing);
522+ expect (find.byKey (const Key ('Breakpoints.medium' )), findsNothing);
523+ expect (find.byKey (const Key ('Breakpoints.mediumDesktop' )), findsNothing);
524+ expect (find.byKey (const Key ('Breakpoints.mediumLarge' )), findsNothing);
525+ expect (
526+ find.byKey (const Key ('Breakpoints.mediumLargeMobile' )), findsNothing);
527+ expect (find.byKey (const Key ('Breakpoints.mediumLargeDesktop' )),
528+ findsNothing);
529+ expect (find.byKey (const Key ('Breakpoints.large' )), findsNothing);
530+ expect (find.byKey (const Key ('Breakpoints.largeMobile' )), findsNothing);
531+ expect (find.byKey (const Key ('Breakpoints.largeDesktop' )), findsNothing);
532+ expect (find.byKey (const Key ('Breakpoints.extraLarge' )), findsNothing);
533+ expect (
534+ find.byKey (const Key ('Breakpoints.extraLargeMobile' )), findsNothing);
535+ expect (
536+ find.byKey (const Key ('Breakpoints.extraLargeDesktop' )), findsNothing);
520537 });
521538
522539 testWidgets (
@@ -526,7 +543,24 @@ void main() {
526543 SimulatedLayout .smallLandscapeMediumPortrait.slot (tester));
527544 await tester.pumpAndSettle ();
528545 expect (find.byKey (const Key ('Breakpoints.smallMobile' )), findsNothing);
529- expect (find.byKey (const Key ('Breakpoints.mediumMobile' )), findsNothing);
546+ expect (find.byKey (const Key ('Breakpoints.mediumMobile' )), findsOneWidget);
547+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
548+ expect (find.byKey (const Key ('Breakpoints.smallDesktop' )), findsNothing);
549+ expect (find.byKey (const Key ('Breakpoints.medium' )), findsNothing);
550+ expect (find.byKey (const Key ('Breakpoints.mediumDesktop' )), findsNothing);
551+ expect (find.byKey (const Key ('Breakpoints.mediumLarge' )), findsNothing);
552+ expect (
553+ find.byKey (const Key ('Breakpoints.mediumLargeMobile' )), findsNothing);
554+ expect (find.byKey (const Key ('Breakpoints.mediumLargeDesktop' )),
555+ findsNothing);
556+ expect (find.byKey (const Key ('Breakpoints.large' )), findsNothing);
557+ expect (find.byKey (const Key ('Breakpoints.largeMobile' )), findsNothing);
558+ expect (find.byKey (const Key ('Breakpoints.largeDesktop' )), findsNothing);
559+ expect (find.byKey (const Key ('Breakpoints.extraLarge' )), findsNothing);
560+ expect (
561+ find.byKey (const Key ('Breakpoints.extraLargeMobile' )), findsNothing);
562+ expect (
563+ find.byKey (const Key ('Breakpoints.extraLargeDesktop' )), findsNothing);
530564 });
531565
532566 testWidgets (
@@ -537,6 +571,22 @@ void main() {
537571 await tester.pumpAndSettle ();
538572 expect (find.byKey (const Key ('Breakpoints.smallMobile' )), findsOneWidget);
539573 expect (find.byKey (const Key ('Breakpoints.largeMobile' )), findsNothing);
574+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
575+ expect (find.byKey (const Key ('Breakpoints.smallDesktop' )), findsNothing);
576+ expect (find.byKey (const Key ('Breakpoints.medium' )), findsNothing);
577+ expect (find.byKey (const Key ('Breakpoints.mediumDesktop' )), findsNothing);
578+ expect (find.byKey (const Key ('Breakpoints.mediumLarge' )), findsNothing);
579+ expect (
580+ find.byKey (const Key ('Breakpoints.mediumLargeMobile' )), findsNothing);
581+ expect (find.byKey (const Key ('Breakpoints.mediumLargeDesktop' )),
582+ findsNothing);
583+ expect (find.byKey (const Key ('Breakpoints.large' )), findsNothing);
584+ expect (find.byKey (const Key ('Breakpoints.largeDesktop' )), findsNothing);
585+ expect (find.byKey (const Key ('Breakpoints.extraLarge' )), findsNothing);
586+ expect (
587+ find.byKey (const Key ('Breakpoints.extraLargeMobile' )), findsNothing);
588+ expect (
589+ find.byKey (const Key ('Breakpoints.extraLargeDesktop' )), findsNothing);
540590 });
541591
542592 testWidgets (
@@ -547,6 +597,48 @@ void main() {
547597 await tester.pumpAndSettle ();
548598 expect (find.byKey (const Key ('Breakpoints.smallMobile' )), findsNothing);
549599 expect (find.byKey (const Key ('Breakpoints.largeMobile' )), findsNothing);
600+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
601+ expect (find.byKey (const Key ('Breakpoints.smallDesktop' )), findsNothing);
602+ expect (find.byKey (const Key ('Breakpoints.medium' )), findsNothing);
603+ expect (find.byKey (const Key ('Breakpoints.mediumDesktop' )), findsNothing);
604+ expect (find.byKey (const Key ('Breakpoints.mediumLarge' )), findsNothing);
605+ expect (find.byKey (const Key ('Breakpoints.mediumLargeMobile' )),
606+ findsOneWidget);
607+ expect (find.byKey (const Key ('Breakpoints.mediumLargeDesktop' )),
608+ findsNothing);
609+ expect (find.byKey (const Key ('Breakpoints.large' )), findsNothing);
610+ expect (find.byKey (const Key ('Breakpoints.largeDesktop' )), findsNothing);
611+ expect (find.byKey (const Key ('Breakpoints.extraLarge' )), findsNothing);
612+ expect (
613+ find.byKey (const Key ('Breakpoints.extraLargeMobile' )), findsNothing);
614+ expect (
615+ find.byKey (const Key ('Breakpoints.extraLargeDesktop' )), findsNothing);
616+ });
617+
618+ testWidgets (
619+ 'Layout for mediumLargeLandscapeMediumPortrait shows correct slot configuration' ,
620+ (WidgetTester tester) async {
621+ await tester.pumpWidget (
622+ SimulatedLayout .mediumLargeLandscapeMediumPortrait.slot (tester));
623+ await tester.pumpAndSettle ();
624+ expect (find.byKey (const Key ('Breakpoints.smallMobile' )), findsNothing);
625+ expect (find.byKey (const Key ('Breakpoints.largeMobile' )), findsNothing);
626+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
627+ expect (find.byKey (const Key ('Breakpoints.smallDesktop' )), findsNothing);
628+ expect (find.byKey (const Key ('Breakpoints.medium' )), findsNothing);
629+ expect (find.byKey (const Key ('Breakpoints.mediumDesktop' )), findsNothing);
630+ expect (find.byKey (const Key ('Breakpoints.mediumLarge' )), findsNothing);
631+ expect (find.byKey (const Key ('Breakpoints.mediumLargeMobile' )),
632+ findsOneWidget);
633+ expect (find.byKey (const Key ('Breakpoints.mediumLargeDesktop' )),
634+ findsNothing);
635+ expect (find.byKey (const Key ('Breakpoints.large' )), findsNothing);
636+ expect (find.byKey (const Key ('Breakpoints.largeDesktop' )), findsNothing);
637+ expect (find.byKey (const Key ('Breakpoints.extraLarge' )), findsNothing);
638+ expect (
639+ find.byKey (const Key ('Breakpoints.extraLargeMobile' )), findsNothing);
640+ expect (
641+ find.byKey (const Key ('Breakpoints.extraLargeDesktop' )), findsNothing);
550642 });
551643 });
552644
@@ -673,6 +765,17 @@ void main() {
673765 expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
674766 expect (find.byKey (const Key ('Breakpoints.mediumAndUp' )), findsOneWidget);
675767 });
768+
769+ testWidgets (
770+ 'slotAndUp shows correct slot for mediumLargeLandscapeMediumPortrait layout' ,
771+ (WidgetTester tester) async {
772+ // mediumLargeLandscapeMediumPortrait layout should show the mediumAndUp slot.
773+ await tester.pumpWidget (
774+ SimulatedLayout .mediumLargeLandscapeMediumPortrait.slotAndUp (tester));
775+ await tester.pumpAndSettle ();
776+ expect (find.byKey (const Key ('Breakpoints.small' )), findsNothing);
777+ expect (find.byKey (const Key ('Breakpoints.mediumAndUp' )), findsOneWidget);
778+ });
676779 });
677780
678781 // Test for `spacing`.
0 commit comments