This week's book giveaways are in the Refactoring and Agile forums. We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line! See this thread and this one for details.
I am planning to use xmlUnit for unit testing xml documents. XML unit supports 'The validity of a piece of XML'. I do not understand what is validity of a piece of XML. Is it validating XML document with XSD?
Normally "well-formed" refers to an XML document which correctly follows the rules of XML, and "valid" refers to a document which also correctly follows the rules of some DTD or schema.
It's likely that whoever wrote that statement knew that and was in fact referring to validation via DTD or schema. But it's possible they were careless and used the wrong term. You would have to ask them exactly what they meant if you wanted to know exactly what they meant.