On 02.07.2003 01:07:08 J.Pietschmann wrote: > I tried to produce a concept for some automated JUnit test...
Great stuff. > Problems: > - PDFInfo unconditionally puts the creation time into the > PDF. This thwarts the whole thing. On my machine I can > disable it temporarily, but there should be a more > sustainable solution. Ideas: > o pass a flag to the renderer which inhibits creation time > creation > o pass a creation date value (can be abused, but abusers can > implement it anyway) > o patch it in the result array before digesting (hack alert) My preference is the second option. > - Source FO line endings: both CVS and ZIP may alter them, > making the source MD5 invalid. I'm not sure whether FixCRLF > can be of use here. Either way, running the tests from Eclipse > unprepared could be a bad idea. Possible fixes: > o have two MD5 in the control one for the source with CRLF, > one with LF only. Makes updating more unconvenient. > o use another FilterStream to transform CRLF->LF before > digesting. Adds unwanted complexity, but probably the way > to go... How about running it through the Canonicalizer from org.apache.xml.security? > - Hidden regressions: a checksum mismatch does not necesarily > cause a visible problem, lets say the author string gets spaces > appended or such. For proper inspection of failures we probably > need a more sophisticated tool than simply display two PDFs > side-by-side. For a starter, a sort of PDF diff which extracts > the streams, uncompresses and displays mismatches with a bit of > context would certainly be valuable. Any takers? I'd still favor the PDF2TIFF with visual diffing approach using GhostScript. I hope I'll have some time to do that once I've finished the IO stuff (Finally made it into the Commons-IO project). BTW, I've started a few JUnit tests myself (tests for basic functionality of the API and for the IO-related classes). Jeremias Maerki --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]