public void AnAliveCellWithTwoOrThreeNeighbors_ShouldResultInALiveCell() { int numberOfNeighbors = 2; Assert.That(GameOfLifeRules.ApplyRules(numberOfNeighbors, State.Alive), Is.EqualTo(State.Alive)); numberOfNeighbors = 3; Assert.That(GameOfLifeRules.ApplyRules(numberOfNeighbors, State.Alive), Is.EqualTo(State.Alive)); }
public void AnDeadCellWithExactlyThreeNeighbors_ShouldResultInAnAliveCell() { int numberOfNeighbors = 3; Assert.That(GameOfLifeRules.ApplyRules(numberOfNeighbors, State.Dead), Is.EqualTo(State.Alive)); }
public void ADeadCellWithNoNeighbors_ShouldResultInADeadCell() { int numberOfNeighbors = 0; Assert.That(GameOfLifeRules.ApplyRules(numberOfNeighbors, State.Dead), Is.EqualTo(State.Dead)); }