citrus icon indicating copy to clipboard operation
citrus copied to clipboard

Validating result of a transform action

Open bthdimension opened this issue 5 years ago • 2 comments

Citrus Version 2.8.0

Question Hi there, I was wondering, if it is possible to validate the result of a transform action in Citrus. I hoped for something like:

transform()
    .source("<some xml>")
    .xslt(new ClassPathResource("xslt/example.xsl"))
    .payload("<actual xml>");

Instead, I can only store the result in a variable, which I can't seem to validate. Is there any way to do this using the Citrus validation methods? Thank you very much!

bthdimension avatar Oct 07 '20 09:10 bthdimension

Not possible in 2.x.

3.x introduces the concept of message processors/transformers that you can apply on a receive message action before the validation is performed.

I also think a transform validation matcher implementation may be useful.

christophd avatar Nov 13 '20 11:11 christophd

Great, looking forward to 3.x :-)

bthdimension avatar Nov 23 '20 17:11 bthdimension