| CPAN Ratings Reviews by Lawrence L. Gilbert | |
| Home | Search | About | Bitcard Account | Login |
A good module for doing simple tests based on XML comparisons. However, I quickly outgrew Test::XML::Deep when I realized that I needed to do more detailed examination of the XML under test when tests failed.
Part of this can be blamed on XML::Simple (and/or XML::Parser?), which can be inconsistent in the data structures it generates. For example, sub-elements may be returned as a hash reference or an array of hash references, all depending on how many sub-elements there are. This plays havoc with Test::Deep (which Test::XML::Deep uses for all comparisons). If testing an element with a number of sub-elements different than what the test expects, I find myself stuck with a diagnostic saying that it expected a hash but got an array (or vice-versa). To get more detail, I resort to using Test::Deep and XML::Simple directly. It would be nice if Test::XML::Deep had some extra smarts to deal with this kind of situation.
Lawrence L. Gilbert - 2009-09-02T12:23:06
|
Perl.org sites
: bugs
| dev
| history
| jobs
| learn
| lists
| use
Site Information and Contacts |
|