Verifying the message content is an essential part of the Citrus integration tests. The test needs to make sure that the exchanged messages are as expected. Each message received can be validated with a special message validator implementation.
Validators
XML
Validate XML messages with body, headers, schema validation and XPath expressions.
→ XML examples
Json
Validate Json messages with body, headers, schema validation and JsonPath expressions.
→ Json example
Text
Plain text message validation with ignore expression support.
→ Text example
Groovy
Validate message content with Groovy scripts and tools such as Json/XML slurper.
→ Groovy example
Binary
Validate binary message content.
→ Binary example
XHTML
Validate HTML pages with XHTML message validator.
→ XHTML example
YAML
Coming soon!
Are you missing something? Please reach out and get involved!