Add support for XML testing

Test reformatted xml, so that we don't fail in case attributes are
generated in different order.

Signed-off-by: Michal Čihař <michal@cihar.com>