[lxml-dev] xslt coverage

Dirk Rothe d.rothe at semantics.de
Tue Dec 16 17:55:51 CET 2008


On Tue, 16 Dec 2008 12:42:35 +0100, Stefan Behnel <stefan_ml at behnel.de>  
wrote:

> Dirk Rothe wrote:
>> are there any possibilities to get something like a line coverage from a
>> xsl-transformation. That would be pretty useful, if integrated in a
>> test-code-coverage run.
>
> There's the profiler (pass "profile_run=True" to the XSLT run), but it
> won't give you line coverage.
>
> http://codespeak.net/lxml/api/lxml.etree.XSLT-class.html#__call__

jep, I've seen that. Would be quite a task to generate a "function-level"  
report by extracting the template-matches. (with line numbers, respecting  
xsl:include ...) One would have to assume full coverage of all the  
conditional branches.

Hmm, maybe I will try it some day :).

thnx, dirk



More information about the lxml-dev mailing list