### Question:
ClassifierInstanceValidator implements Validator<ClassifierInstance> { @Override public ValidationResult validate(ClassifierInstance ci) { for (ParameterValue param : ci.getParameterValue()) { ValidationResult validationResult = validate(param, ci.getName()); if (!validationResult.isValid()) { return validationResult; } } return new ValidationResultBuilder().success().build(); } ClassifierInstanceValidator(SupportedClassifierDefinition constraint, RendererName rendererName); @Override ValidationResult validate(ClassifierInstance ci); ValidationResult validate(ParameterValue param, ClassifierName ciName); boolean containsParamsForValidation(); @Nonnull RendererName getRendererName(); @Nonnull Set<ParameterName> getSupportedParameters(); @Nonnull ClassifierDefinitionId getClassifierDefinitionId(); @Nullable ClassifierDefinitionId getParentClassifierDefinitionId(); @Nullable Validator<ClassifierInstance> getParentValidator(); void setParentValidator(@Nullable ClassifierInstanceValidator parentValidator); @Override int hashCode(); @Override boolean equals(Object obj); @Override java.lang.String toString();  }### Answer:
@Test public void testValidate() { ClassifierInstanceBuilder ciBuilder = new ClassifierInstanceBuilder(); ciBuilder.setName(new ClassifierName(CLASSIFIER1)); ciBuilder.setParameterValue(ImmutableList .of(new ParameterValueBuilder().setName(new ParameterName(PARAM_NAME)).setIntValue(100L).build())); SupportedClassifierDefinition constraint = new SupportedClassifierDefinitionBuilder() .setClassifierDefinitionId(cdId) .setParentClassifierDefinitionId(parentCdId) .setSupportedParameterValues(supportedParameterValues) .build(); RendererName rendererName = new RendererName(RENDERER); ClassifierInstanceValidator validator = new ClassifierInstanceValidator(constraint, rendererName); assertEquals(new ValidationResultBuilder().success().build(), validator.validate(ciBuilder.build())); }