XSLT unit test
Posted: Fri Sep 01, 2006 9:12 pm
I would like to see Oxygen support XSLT unit testing. In the simplest case I imagine something like this: I embed, say, in an annotation in a template, several testing scenarios. Each scenario consists of a context, any parameters I might wish to supply to the template, and the expected outcome of the transformation. When instructed to unit-test the template Oxygen would run each scenario by invoking the template in the specified context with the specified parameters and comparing the output to the expected outcome. It would also be nice if the expected outcome could assume the form of a collection of Schematron-like assertions. A further improvement on this simple case would be allowing tests to be kept separate from the templates in external files and templates to refer to them.