public void ItShouldBeWithoutPirates() { //Arrange var stubCell = new StubCell(); //Assert stubCell.Pirates.ShouldBeEmpty(); }
public void ItShouldBeNotDiscovered() { //Arrange var stubCell = new StubCell(); //Assert stubCell.Discoverd.ShouldBeFalse(); }
public void PirateShouldBeReadonly() { //Arrange var stubCell = new StubCell(); //Assert stubCell.Pirates.ShouldBeReadonlyCollection(); }
public void ItShouldNotBeMultistep() { //Arrange var stubCell = new StubCell(); //Assert stubCell.MultiStep.ShouldBeFalse(); }
public void ItShouldBeTerminal() { //Arrange var stubCell = new StubCell(); //Assert stubCell.Terminal.ShouldBeTrue(); }
public void ItShouldCreatePosition() { //Arrange var stubCell = new StubCell(3, 4); //Assert stubCell.Position.ShouldBeNotNull(); stubCell.Position.ShouldBeEqual(new Position(3, 4)); }
public void WhenAddPirateShouldSetPosition() { //Arrange var pirate = Black.Pirate; var stubCell = new StubCell(3, 4); //Act stubCell.AddPirate(pirate); //Assert pirate.Position .ShouldBeEqual(new Position(3, 4)); }
public void HeShouldBeTransferedToShip() { //Arrange var stubCell = new StubCell(4, 4); stubCell.PirateComing(black); black.Position.ShouldBeEqual(stubCell.Position); //Act baloonCell.PirateComing(black); //Assert baloonCell.Pirates.ShouldBeEmpty(); black.Position.ShouldBeEqual(Black.Ship.Position); }
public void HeCanNotStayIfThereAreFoes() { var foe = Red.Pirate; amazonCell.PirateComing(foe); var stubCell = new StubCell(); stubCell.AddPirate(pirate); // Act amazonCell.PirateCanComeFrom(stubCell); // Assert amazonCell.Pirates.ShouldContain().Exact(foe); }
public void HeCanStayIfThereAreAlly() { var player = new Player(TeamType.Red, TeamType.Black, new TestEmptyRules()); var ally = player.GetNextTeam().Pirates.Current; pirate = player.GetNextTeam().Pirates.Current; amazonCell.PirateComing(ally); var stubCell = new StubCell(); stubCell.AddPirate(pirate); // Act amazonCell.PirateCanComeFrom(stubCell); amazonCell.PirateComing(pirate); // Assert amazonCell.Pirates.ShouldContain().Elements(ally, pirate); }
public void HeCanStayIfThereAreAlly() { var ally = Red.Pirate; // ally.Aliance = TeamType.Black; // pirate.Aliance = TeamType.Red; fortressCell.PirateComing(ally); var stubCell = new StubCell(); stubCell.AddPirate(pirate); // Act fortressCell.PirateCanComeFrom(stubCell); fortressCell.PirateComing(pirate); // Assert fortressCell.Pirates.ShouldContain().Elements(ally, pirate); }
public void Init() { pirate = Black.Pirate; stubCell = new StubCell(); }