public void When_Set_Is_Played_Then_Score_Is_Changed() { //act _setResult.Play(); //Assert Assert.True(_setResult.Player1Score > 0 || _setResult.Player2Score > 0); }
public SetResult ConductSet(Player player1, Player player2) { var setResult = new SetResult(player1, player2); while (!_setRules.All(r => r.IsAchieved(setResult))) { setResult.Play(); } setResult.IsFinished = true; setResult.Winner = setResult.Player2Score > setResult.Player1Score ? player2 : player1; return(setResult); }