private void ScorePlayerAgainst(Player player, Player playerAgainst) { player.Scored(); if (player.Score == Score.Advantage && playerAgainst.Score == Score.Advantage) { player.Score = Score.Forty; playerAgainst.Score = Score.Forty; } else if (player.Score == Score.Advantage && playerAgainst.Score < Score.Forty){ player.Score = Score.Game; } }
public void With_new_Player_and_Scored_Score_Should_Fifteen() { var player = new Player(); player.Scored(); Assert.AreEqual(Score.Fifteen, player.Score); }
public void New_Player_Score_Should_Love() { var player = new Player(); Assert.AreEqual(Score.Love,player.Score); }
public Game() { PlayerOne = new Player(); PlayerTwo = new Player(); }