public void PlacesLinemanInCorrectLocations() { FormationPlacer formationPlacer = new FormationPlacer(fakePlacementRuleFactory); Location expectedLocation = new Location(0, 0); PlacedFormation placedFormation = formationPlacer.ToPlacedFormation(formation); bool inExpectedLocation = placedFormation.center.location == expectedLocation; Assert.True(inExpectedLocation); }
public void PlacesTacklesInCorrectLocation() { FormationPlacer formationPlacer = new FormationPlacer(fakePlacementRuleFactory); Location expectedLeftTackleLocation = new Location(-8, 0); Location expectedRightTackleLocation = new Location(8, 0); PlacedFormation placedFormation = formationPlacer.ToPlacedFormation(formation); bool leftTackleInExpectedLocation = placedFormation.leftTackle.location == expectedLeftTackleLocation; bool rightTackleInExpectedLocation = placedFormation.rightTackle.location == expectedRightTackleLocation; Assert.True(leftTackleInExpectedLocation); Assert.True(rightTackleInExpectedLocation); }
public void PlacesGuardsInCorrectLocation() { FormationPlacer formationPlacer = new FormationPlacer(fakePlacementRuleFactory); Location expectedLeftGuardLocation = new Location(-4, 0); Location expectedRightGuardLocation = new Location(4, 0); PlacedFormation placedFormation = formationPlacer.ToPlacedFormation(formation); bool leftGuardInExpectedLocation = placedFormation.leftGuard.location == expectedLeftGuardLocation; bool rightGuardInExpectedLocation = placedFormation.rightGuard.location == expectedRightGuardLocation; Assert.True(leftGuardInExpectedLocation); Assert.True(rightGuardInExpectedLocation); }