Keep the gym mode options within the start page

This commit is contained in:
Roland Geider
2026-10-25 16:19:42 +01:00
parent f0075b096a
commit fc237bca15
3 changed files with 258 additions and 215 deletions

View File

@@ -314,4 +314,26 @@ void main() {
expect(hint, findsNothing);
});
});
testWidgets('The opened options fit a short screen, e.g. with the keyboard up', (tester) async {
tester.view.physicalSize = const Size(400, 480);
tester.view.devicePixelRatio = 1;
addTearDown(tester.view.reset);
await tester.pumpWidget(
UncontrolledProviderScope(
container: container,
child: MaterialApp(
locale: const Locale('en'),
localizationsDelegates: appLocalizationsDelegates,
supportedLocales: AppLocalizations.supportedLocales,
home: Scaffold(body: StartPage(PageController())),
),
),
);
await tester.pumpAndSettle();
await tester.tap(find.byKey(const ValueKey('gym-mode-options-tile')));
await tester.pumpAndSettle();
expect(tester.takeException(), isNull);
});
}