fix: coverage

pull/212/head
alestiago 3 years ago
parent 7dcde691d1
commit d6f4a2e719

@ -37,7 +37,7 @@ class SparkyComputerController
}
/// {@template sparky_turbo_charge_sensor_ball_contact_callback}
/// Turbo charges the [Ball] when it enters the [SparkyComputer].
/// Turbo charges the [Ball] when it enters the [SparkyComputer]
/// {@endtemplate}
@visibleForTesting
class SparkyTurboChargeSensorBallContactCallback

@ -8,21 +8,14 @@ import 'package:pinball/game/game.dart';
import '../../helpers/helpers.dart';
void main() {
group('SparkyComputerController', () {
group('ControlledSparkyComputer', () {
TestWidgetsFlutterBinding.ensureInitialized();
final flameTester = FlameTester(EmptyPinballTestGame.new);
late ControlledSparkyComputer controlledSparkyComputer;
setUp(() {
controlledSparkyComputer = ControlledSparkyComputer();
});
test('can be instantiated', () {
expect(
SparkyComputerController(controlledSparkyComputer),
isA<SparkyComputerController>(),
);
flameTester.test('loads correctly', (game) async {
final sparkyComputer = ControlledSparkyComputer();
await game.ensureAdd(sparkyComputer);
expect(game.children, contains(sparkyComputer));
});
flameTester.testGameWidget(

Loading…
Cancel
Save