@Test public void check_5_chars_min_for_id() { assertTrue(validationToTest.validate("12345").isValid()); assertFalse(validationToTest.validate("1234").isValid()); assertFalse(validationToTest.validate("123").isValid()); assertFalse(validationToTest.validate("").isValid()); }
@Override protected void validate(ValidationContext<String> context) { validateNotNull(context); validateWithoutWhitespaces(context); validateOnlyAlphabeticDigitOrAllowedParts(context, '.','-','_'); validateLength(context); }
MappingIdValidationImpl extends AbstractSimpleStringValidation implements MappingIdValidation { @Override protected void validate(ValidationContext<String> context) { validateNotNull(context); validateWithoutWhitespaces(context); validateOnlyAlphabeticDigitOrAllowedParts(context, '.','-','_'); validateLength(context); } }
MappingIdValidationImpl extends AbstractSimpleStringValidation implements MappingIdValidation { @Override protected void validate(ValidationContext<String> context) { validateNotNull(context); validateWithoutWhitespaces(context); validateOnlyAlphabeticDigitOrAllowedParts(context, '.','-','_'); validateLength(context); }  }
MappingIdValidationImpl extends AbstractSimpleStringValidation implements MappingIdValidation { @Override protected void validate(ValidationContext<String> context) { validateNotNull(context); validateWithoutWhitespaces(context); validateOnlyAlphabeticDigitOrAllowedParts(context, '.','-','_'); validateLength(context); }   }
MappingIdValidationImpl extends AbstractSimpleStringValidation implements MappingIdValidation { @Override protected void validate(ValidationContext<String> context) { validateNotNull(context); validateWithoutWhitespaces(context); validateOnlyAlphabeticDigitOrAllowedParts(context, '.','-','_'); validateLength(context); }    }