void (List<Chunk<String>> expected, Collection<Chunk<String>> nodes) { List<Chunk<String>> realNodes = new ArrayList<>(nodes); assertEquals(expected.size(), realNodes.size()); assertEquals(new HashSet<>(expected), new HashSet<>(realNodes)); }