/**
   * Validate bean property in the base class aganist new value.
   *
   * @param beanClass
   * @param property
   * @param value
   * @return
   */
  protected InvalidValue[] validateClass(
      FacesContext facesContext, Class<? extends Object> beanClass, String property, Object value) {
    ClassValidator<? extends Object> classValidator = getValidator(facesContext, beanClass);

    InvalidValue[] invalidValues = classValidator.getPotentialInvalidValues(property, value);
    return invalidValues;
  }
Esempio n. 2
0
 private void isWrongEmail(String email) {
   assertEquals("Right email", 1, userValidator.getPotentialInvalidValues("email", email).length);
 }