diff --git a/test/game/components/crossing_ramp_test.dart b/test/game/components/crossing_ramp_test.dart index 84f41fc4..0db1e569 100644 --- a/test/game/components/crossing_ramp_test.dart +++ b/test/game/components/crossing_ramp_test.dart @@ -67,6 +67,7 @@ void main() { position: Vector2.zero(), categoryBits: RampType.all.maskBits, ); + await game.ready(); await game.ensureAdd(ramp); expect(game.contains(ramp), isTrue); diff --git a/test/game/components/jetpack_ramp_test.dart b/test/game/components/jetpack_ramp_test.dart index 24089496..1305da6f 100644 --- a/test/game/components/jetpack_ramp_test.dart +++ b/test/game/components/jetpack_ramp_test.dart @@ -66,7 +66,8 @@ void main() { await game.ready(); await game.ensureAdd(jetpackRamp); - final rampAreas = game.children.whereType().toList(); + final rampAreas = + jetpackRamp.children.whereType().toList(); expect(rampAreas.length, 2); }, ); @@ -80,7 +81,8 @@ void main() { await game.ready(); await game.ensureAdd(jetpackRamp); - final rampAreas = game.children.whereType().toList(); + final rampAreas = + jetpackRamp.children.whereType().toList(); for (final rampArea in rampAreas) { expect(rampArea.body.bodyType, equals(BodyType.static)); } diff --git a/test/game/components/sparky_ramp_test.dart b/test/game/components/sparky_ramp_test.dart index eb0c8b77..2ceb6e2c 100644 --- a/test/game/components/sparky_ramp_test.dart +++ b/test/game/components/sparky_ramp_test.dart @@ -32,7 +32,7 @@ void main() { await game.ensureAdd(sparkyRamp); expect( - () => game.children.singleWhere( + () => sparkyRamp.children.singleWhere( pathwaySelector(position), ), returnsNormally, @@ -66,7 +66,8 @@ void main() { await game.ready(); await game.ensureAdd(sparkyRamp); - final rampAreas = game.children.whereType().toList(); + final rampAreas = + sparkyRamp.children.whereType().toList(); expect(rampAreas.length, 2); }, ); @@ -80,7 +81,8 @@ void main() { await game.ready(); await game.ensureAdd(sparkyRamp); - final rampAreas = game.children.whereType().toList(); + final rampAreas = + sparkyRamp.children.whereType().toList(); for (final rampArea in rampAreas) { expect(rampArea.body.bodyType, equals(BodyType.static)); }