@Test
public void testResolveSubjectsFailsOnUnresolved() {

  when(subjectResolver.resolveSubject(isA(String.class))).thenReturn(Subject.builder().build());
  List<String> acl = list(UUID.randomUUID().toString(), "name", UUID.randomUUID().toString());
  InvalidArgumentException ex = assertThrows(InvalidArgumentException.class, () -> handler.resolveSubjects(acl));
  assertEquals(set("acl[0]", "acl[2]"), set(ex.getValidationErrors(), InvalidArgumentException.ValidationError::getProperty));
  verify(subjectResolver, times(2)).resolveSubject(isA(UUID.class));
  verify(subjectResolver).resolveSubject("name");
}