[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Verifying large XSL transform output
Another vote here for round tripping and comparing the result with the source using a specifically built comparison tool. I have a project under way right now doing that. Its a non-trivial amount of work, but you have to test somehow, and I don't know how you would write and execute comprehensive test cases otherwise. The comparison tool will be a lot simpler than the transformations, so it is easy to test manually. This approach has the advantage that the entire body of input XML can be the test data, leaving no corner cases uncovered. Greg On Wed, Feb 12, 2014 at 4:26 AM, Tony Graham <tgraham@xxxxxxxxxx> wrote: > On Tue, February 11, 2014 4:31 pm, Matthew Stoeffler wrote: >> On Feb 11, 2014, at 11:15 AM, Graydon wrote: >> >> Are you trying to tell if the transformation worked to the specification >> (as distinct from producing valid output!), or if you didn't lose any >> text content? >> >> The issue here is being certain I have all the source content, or at least >> all the source content I require. > > For a large conversion project where some clients of the business have a > long lead time for any changes in the format of XML they receive, we > round-trip from the new format to the old for delivery to those clients > and also use the round-tripped XML in development for checking that we > hadn't missed anything in the conversion. > > We couldn't quite put Humpty-Dumpty together again in the round-tripping, > so we normalise away the ignorable differences before doing the > comparison, which boils down to deep-equal() plus counting comments. > > That approach may not be as much use if you're producing an archive format > and aren't going back in the other direction, of course. > > Regards, > > > Tony Graham tgraham@xxxxxxxxxx > Consultant http://www.mentea.net > Chair, Print and Page Layout Community Group @ W3C XML Guild member > -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- > Mentea XML, XSL-FO and XSLT consulting, training and programming
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|