@Test
void validate() {

    validator.beanClasses.put(Classes.className(TestBean.class), Void.class);
    assertThatThrownBy(() -> validator.validate(TestBean.class))
        .isInstanceOf(Error.class).hasMessageContaining("found bean class with duplicate name");
}