On Sep 11, 2006, at 11:58 PM, Gabor Szabo wrote: > Returning to my soapbox, what if one of the values pasted into the > template is an invalid piece of HTML code. e.g. '23 < 42'. > > The templates are still valid but the generated HTML is not.
Very much true, although what I'm attempting to test is the structure of the HTML in the templates themselves. I think testing the validity of output of HTML::Template templates a whole different cookie - and wouldn't be hurt by valid HTML in the template to begin with. I'm not sure what the solution is to that, since each template wants a different set of variables with different values being different for each value. Perhaps a solution to that would be to create a WWW::Mechanize robot that visits all the screens (known) to exist in the webapp and report of any problems with the HTML. I *guess* that would be fun, although it still doesn't test every instance of what gets passed to HTML::Template. Another solution would be to filter all the variables that are sent to HTML::Template before they are. HTML::Template is only called directly in one place in the app, so adding that wouldn't be a problem. Another may be just to enforce the various ESCAPE parameters in the HTML::Templates where they'd do the most good. That would be as easy as appending the program's style guide. I may worry about that later (and funny, I can't find anything about validating those conditions). At the moment, I'm fixing the errors my fairly simple test is turning up in my templates. I'm fairly pleased of the results I've gotten back, most of the errors reported are, in fact, goofs in the HTML of the HTML::Template templates. Justin Simoni -- :: is an eccentric artist, living and working in Denver, Colorado :: URL: http://justinsimoni.com :: Mailing List - http://justinsimoni.com/mailing_list.html On Sep 11, 2006, at 11:58 PM, Gabor Szabo wrote: > On 9/12/06, Justin Simoni <[EMAIL PROTECTED]> wrote: >> >> And, from the small set of files I've tested, looks like they're all >> structurally sound HTML files (except for the problems the tests did >> find), which was a hunch of mine that HTML::Template templates would >> be (sans the embedded comments in tags), since HTML::Template sort of >> mandates a clean separation between design and code. > > Returning to my soapbox, what if one of the values pasted into the > template is an invalid piece of HTML code. e.g. '23 < 42'. > > The templates are still valid but the generated HTML is not. > > Gabor > > ---------------------------------------------------------------------- > --- > Using Tomcat but need to do more? Need to support web services, > security? > Get stuff done quickly with pre-integrated technology to make your > job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache > Geronimo > http://sel.as-us.falkag.net/sel? > cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Html-template-users mailing list > Html-template-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/html-template-users > ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Html-template-users mailing list Html-template-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/html-template-users