Search in sources :

Example 1 with EnclosedMessageWithoutAnnotationFieldValue

use of io.spine.test.validate.msg.EnclosedMessageWithoutAnnotationFieldValue in project core-java by SpineEventEngine.

the class MessageValidatorShould method consider_field_is_valid_if_no_valid_option_set.

@Test
public void consider_field_is_valid_if_no_valid_option_set() {
    final RequiredStringFieldValue invalidEnclosedMsg = RequiredStringFieldValue.getDefaultInstance();
    final EnclosedMessageWithoutAnnotationFieldValue msg = EnclosedMessageWithoutAnnotationFieldValue.newBuilder().setOuterMsgField(invalidEnclosedMsg).build();
    validate(msg);
    assertIsValid(true);
}
Also used : EnclosedMessageWithoutAnnotationFieldValue(io.spine.test.validate.msg.EnclosedMessageWithoutAnnotationFieldValue) CustomMessageRequiredStringFieldValue(io.spine.test.validate.msg.CustomMessageRequiredStringFieldValue) RequiredStringFieldValue(io.spine.test.validate.msg.RequiredStringFieldValue) Test(org.junit.Test)

Aggregations

CustomMessageRequiredStringFieldValue (io.spine.test.validate.msg.CustomMessageRequiredStringFieldValue)1 EnclosedMessageWithoutAnnotationFieldValue (io.spine.test.validate.msg.EnclosedMessageWithoutAnnotationFieldValue)1 RequiredStringFieldValue (io.spine.test.validate.msg.RequiredStringFieldValue)1 Test (org.junit.Test)1