diff --git a/test/widgets/compose_box_test.dart b/test/widgets/compose_box_test.dart index ae670f0c10..666e1941f4 100644 --- a/test/widgets/compose_box_test.dart +++ b/test/widgets/compose_box_test.dart @@ -51,7 +51,13 @@ void main() { final controllerKey = GlobalKey(); await tester.pumpWidget(TestZulipApp(accountId: eg.selfAccount.id, - child: ComposeBox(controllerKey: controllerKey, narrow: narrow))); + child: Column( + // This positions the compose box at the bottom of the screen, + // simulating the layout of the message list page. + children: [ + const Expanded(child: SizedBox.expand()), + ComposeBox(controllerKey: controllerKey, narrow: narrow), + ]))); await tester.pumpAndSettle(); return controllerKey;