nextFriends, new tests and refactor