xsl-list
[Top] [All Lists]

Re: [xsl] xslt test automation

2010-11-30 12:56:08
On Tue, 30 Nov 2010 17:14:16 +0000
Philip Fearon <pgfearo(_at_)googlemail(_dot_)com> wrote:

What's being tested (versions ....)
When its being tested, who by?
Test program (version... parts ...)
software in use (xslt engine, java vsn, OS)

This data should be in the summary report, most of it extracted
automatically, I don't think it all needs to be specified in the input
environment. The output summary also confirms the input parameters
etc. that were ultimately used by the test environment, which should
of course match those specified in the input environment XML.

You asked how to express the test input environment?
To me that means in what software environment the XSLT is being
tested in? Agreed it needs collating in the output. 
It defines the test / input environment though. 



Expected output file.


(2) the XML summarising the output
Common to any testing?
No, just to XSLT testing/

My point was that this summary is common to any
testing, XSLT or otherwise?


reference to test definition(s)
Test count run
Tests passed, failed, not run.

Oddity.
 templates [matched/named]used
 Templates [matched/named] not used.
 Input elements not matched (??? If applicable)
All included in the output summary. Unmatched templates appear as
errors

Ah, you're saying what you already do? I understand. 
It may not be an error though? For this run I may
not need the output of a particular template?
Report it, but let the user define it as an error or otherwise?



 functions used.
 XML comparison of expected/actual from each template.... Possible?
     Not sure. How to encapsulate depth? XMLdiff definitely needed.
Agree XMLdiff would be invaluable for regression testing, but this
isn't the only kind of test.

You didn't classify the 'kinds' of tests, hence IMHO it is 
needed in a GP XSLT test setup?



I've previously appealed for views on a common format for the XML
output summary but this wasn't met with enthusiasm at the time.

Define what's wanted first Phil? Defining XML wrappers ins't magic.
W3C has a markup IIRC?
The requirement is that all output data not normally accessible to
XSLT-based frameworks is collated into a single XML resource, that can
be.

E.g. test environment etc. For testing I guess you could call
that metadata? 

"The requirement is that all output data not normally accessible to
 XSLT-based frameworks is collated into a single XML resource,"

As a requirement of what testing you want to do I find that a bit 
on the vague side? 

Given a requirement to 'produce a transform to take Schema X instance
and produce something to Schema Y', what requirement would you
put on the testing of the work done by the XSLT author?

Some easy ones, some not so easy. "Has he/she done their job/what was
asked of them" is part of the question to answer. 

I'm sure there's lots more than that. 

Far easier to test XSLT 2.0 functions against expected values etc.
How much can you mess with the XSLT being tested before someone cries
foul? 

If you want to test only parts of the transform, would you need to
include the default templates? Some very grey areas Phil.




-- 

regards 

-- 
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>