I want to check a list that is inside a Map value in a unit test using the AssertJ library:
public class Group {
List<Player> players = new ArrayList<>();
public Group(List<Player> players) {
this.players.addAll(players);
}
}
Map<Character, Group> generatedGroups = receiveFromAnyMethod();
Inside a Map I have this:
A: Group A -> players(playerA, playerB)
How I check a list inside a Group? I think I should use a extracting, flatExtracting methods, but I don't know how.