fix: apply code review

pull/195/head
arturplaczek 3 years ago
parent 97fc49ee9c
commit 2a72e3a545

@ -27,13 +27,12 @@ class PlayButtonOverlay extends StatelessWidget {
showDialog<void>(
context: context,
builder: (_) {
final width = MediaQuery.of(context).size.width * 0.9;
final height = MediaQuery.of(context).size.height * 0.9;
final height = MediaQuery.of(context).size.height * 0.5;
return Center(
child: SizedBox(
height: height,
width: width,
width: height * 1.4,
child: const CharacterSelectionDialog(),
),
);

@ -5,7 +5,6 @@
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
import 'package:flutter_bloc/flutter_bloc.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:leaderboard_repository/leaderboard_repository.dart';
import 'package:mocktail/mocktail.dart';
@ -29,12 +28,9 @@ void main() {
testWidgets('renders PinballGamePage', (tester) async {
await tester.pumpWidget(
RepositoryProvider<PinballAudio>(
create: (_) => pinballAudio,
child: App(
leaderboardRepository: leaderboardRepository,
pinballAudio: pinballAudio,
),
App(
leaderboardRepository: leaderboardRepository,
pinballAudio: pinballAudio,
),
);
expect(find.byType(PinballGamePage), findsOneWidget);

@ -33,7 +33,7 @@ void main() {
verify(gameFlowController.start).called(1);
});
testWidgets('is showing CharacterSelectionDialog when tapped',
testWidgets('displays CharacterSelectionDialog when tapped',
(tester) async {
await tester.pumpApp(PlayButtonOverlay(game: game));

@ -83,7 +83,7 @@ void main() {
verify(() => themeCubit.characterSelected(SparkyTheme())).called(1);
});
testWidgets('is showing how to play dialog when start is tapped',
testWidgets('displays how to play dialog when start is tapped',
(tester) async {
await tester.pumpApp(
CharacterSelectionView(),

Loading…
Cancel
Save