### Question:
AddedScoreCalculator { public int findWinnerAddedScore(Player winner, Player looser) { int winnerScore = winner.getScore(); int looserScore = looser.getScore(); int playersDiffScore = Math.abs(winnerScore - looserScore); if (winnerScore > looserScore) { int playersDiffLevel = playersDiffScore / WINNER_GREATER_SCORE_MODIFIER; int addedScore = DEFAULT_MODIFIER - playersDiffLevel; if (addedScore < 0) { addedScore = 0; } return addedScore; } else { int playersDiffLevel = playersDiffScore / WINNER_LESS_SCORE_MODIFIER; return DEFAULT_MODIFIER + playersDiffLevel; } }  int findWinnerAddedScore(Player winner, Player looser);  }### Answer:
@Test public void whenScoreEquals() { Player winner = createPlayer(1000); Player looser = createPlayer(1000); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER); }
@Test public void whenWinnerAlmostLessAtOneLevel() { Player winner = createPlayer(1000); Player looser = createPlayer(1074); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER); }
@Test public void whenWinnerLessAtOneLevel() { Player winner = createPlayer(1000); Player looser = createPlayer(1075); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER + 1); }
@Test public void whenWinnerLessAtSomeDiff() { Player winner = createPlayer(1000); Player looser = createPlayer(1920); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER + 12); }
@Test public void whenWinnerAlmostBiggerAtOneLevel() { Player winner = createPlayer(1099); Player looser = createPlayer(1000); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER); }
@Test public void whenWinnerBiggerAtOneLevel() { Player winner = createPlayer(1100); Player looser = createPlayer(1000); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(MIN_MODIFIER - 1); }
@Test public void whenWinnerBiggerAtSomeDiff() { Player winner = createPlayer(1799); Player looser = createPlayer(1000); int actual = addedScoreCalculator.findWinnerAddedScore(winner, looser); assertThat(actual).isEqualTo(0); }