Search in sources :

Example 1 with ByteStringFieldValidator

use of io.spine.validate.ByteStringFieldValidator in project core-java by SpineEventEngine.

the class FieldValidatorFactoryShould method create_ByteString_field_validator.

@Test
public void create_ByteString_field_validator() {
    final FieldDescriptor field = RequiredByteStringFieldValue.getDescriptor().getFields().get(0);
    final FieldValidator validator = FieldValidatorFactory.create(field, new Object(), FIELD_PATH);
    assertTrue(validator instanceof ByteStringFieldValidator);
}
Also used : ByteStringFieldValidator(io.spine.validate.ByteStringFieldValidator) FloatFieldValidator(io.spine.validate.FloatFieldValidator) StringFieldValidator(io.spine.validate.StringFieldValidator) LongFieldValidator(io.spine.validate.LongFieldValidator) BooleanFieldValidator(io.spine.validate.BooleanFieldValidator) ByteStringFieldValidator(io.spine.validate.ByteStringFieldValidator) FieldDescriptor(com.google.protobuf.Descriptors.FieldDescriptor) Test(org.junit.Test)

Aggregations

FieldDescriptor (com.google.protobuf.Descriptors.FieldDescriptor)1 BooleanFieldValidator (io.spine.validate.BooleanFieldValidator)1 ByteStringFieldValidator (io.spine.validate.ByteStringFieldValidator)1 FloatFieldValidator (io.spine.validate.FloatFieldValidator)1 LongFieldValidator (io.spine.validate.LongFieldValidator)1 StringFieldValidator (io.spine.validate.StringFieldValidator)1 Test (org.junit.Test)1