Here is an example of using MarkupBuilder to create a new XML file:
This will output XML similar to what we have been using in previous examples. If we want we can take this further and compare what we produced with our sample XML. To do this, make sure the following class is added to your CLASSPATH:
XmlExamples.groovy
Here is the previous example extended to compare our newly created XML with our sample XML using XMLUnit:
Labels