Paraphrases part of t/modules/filter.t, but note that 
application/xml does not fit the generated xml.
