Migrated DomDocument class.
Removed useless line.
Improved error handling for XML file saving.
Allow model tests with empty table sets by default.
Moved metadata XML generation to new storage class.