|Come for the quick hacks, stay for the epiphanies.
Comparing HTML snippetsby szabgab (Priest)
|on Feb 28, 2014 at 07:14 UTC
szabgab has asked for the wisdom of the Perl Monks concerning the following question:
Hi, I need to test some HTML files if they contain the expected markup and I thought what if I gave an expected sub-html and then use something (e.g. HTML::TreeBuilder to check if the tree built up from the expected snippet matches some subtree of the received HTML. This should disregard white space where they are irrelevant and it would disregard the order of attributes inside a tag. So
would be accepted even if it was written
Is this a good idea? What problems will arise? Is there a module already doing something like this?