Class EventStreamTestsTraitValidator
java.lang.Object
software.amazon.smithy.model.validation.AbstractValidator
software.amazon.smithy.protocoltests.traits.eventstream.EventStreamTestsTraitValidator
- All Implemented Interfaces:
Validator
Validates event stream test cases. It performs the following validations for each test case:
- Validates that the initial request params match the modeled initial request.
- Validates that the initial request matches the initial request shape if set.
- Validates that the initial response params match the modeled initial response.
- Validates that the initial response matches the initial response shape if set.
- Validates that the vendor params match the vendor params shape if set.
- Validates that there is at least one event or initial message defined.
- Validates that the ID is unique.
- If the event is a REQUEST event and it has params, validates that the operation has an input stream.
- If the event is a RESPONSE event and it has params, validates that the operation has an output stream.
- If the event has params, validates that it matches an event in the event stream.
- If the body media type is set to XML or JSON, validate that the body parseable. \
- Validates that the vendor params match the vendor params shape if set.
-
Field Summary
Fields inherited from interface software.amazon.smithy.model.validation.Validator
MODEL_DEPRECATION, MODEL_ERROR -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionValidates a model and returns a list of validation events.Methods inherited from class software.amazon.smithy.model.validation.AbstractValidator
createEvent, createEvent, createEvent, createEvent, danger, danger, danger, danger, danger, danger, danger, danger, error, error, error, error, error, error, error, error, getName, note, note, note, note, note, note, note, note, warning, warning, warning, warning, warning, warning, warning, warning
-
Constructor Details
-
EventStreamTestsTraitValidator
public EventStreamTestsTraitValidator()
-
-
Method Details
-
validate
Description copied from interface:ValidatorValidates a model and returns a list of validation events.- Parameters:
model- Model to validate.- Returns:
- List of validation events.
-