It sounds to me as if you're testing too large a chunk of functionality. You're describing integration tests, not unit tests. This is too big to be a "unit".

I'd put in a mock XML generator that captures the data structure you're passing through to the thing that make XML/XHTML. Verify that the data structure you're passing to the XML/XHTML generator is correct. Then, I'd test your XML/XHTML generator completely separately. Those are the "units" involved here.


My criteria for good software:
  1. Does it work?
  2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?

In reply to Re: When Test Suites Attack by dragonchild
in thread When Test Suites Attack by Ovid

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":