public static void PlayerOneScore(this TennisGame tennisGame, int points) { for (int i = 0; i < points; i++) { tennisGame.PlayerOneScore(); } }
public void PlayerOneScoreThreePoints40Love() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(3); Assert.Equal("40 love", tennisGame.GetScore()); }
public void PlayerOneScoreTwoPoints30Love() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(2); Assert.Equal("30 love", tennisGame.GetScore()); }
public void PlayerOneScorePoint15Love() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(1); Assert.Equal("15 love", tennisGame.GetScore()); }
public void DeuceThreePoints() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(3); tennisGame.PlayerTwoScore(3); Assert.Equal("deuce", tennisGame.GetScore()); }
public void BothScoreTwice() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(2); tennisGame.PlayerTwoScore(2); Assert.Equal("30 all", tennisGame.GetScore()); }
public void WinnerPlayerTwo() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(2); tennisGame.PlayerTwoScore(4); Assert.Equal("winner player2", tennisGame.GetScore()); }
public void AdvantagePlayerTwo() { var tennisGame = new TennisGame(); tennisGame.PlayerOneScore(4); tennisGame.PlayerTwoScore(5); Assert.Equal("advantage player2", tennisGame.GetScore()); }
public void PlayerOneWinFirstBall() { _game.PlayerOneScore(); Assert.AreEqual("fifteen-love", _game.GetScore()); }