I am proud to announce a new version of XSpec, the XSLT and
XQuery unit testing framework. The main changes are:
- improved XQuery support
- delivered as an EXPath package
- new tests (of XSpec itself)
- numerous bug fixes
- new XProc harnesses for several processors
- improved shell scripts and Ant build file
- oXygen framework for editing
- RNC schema for Emacs nXML mode
You can download it, as usual, from the project website at:
http://code.google.com/p/xspec/downloads/
If your processor supports the EXPath packaging system, you can
just give it the XAR package contained in the release ZIP file.
New XProc pipeline "test harnesses" have developed. They have
been developed with XML Calabash, and allow you to run your tests
on (in alphabetical order):
- BaseX (using the standalone processor)
- eXist (by sending the query through the REST interface)
- MarkLogic (by using Calabash's extension steps)
- Saxon, both XSLT and XQuery
- Zorba
As always, feedback welcome on this list. Enjoy!
Thanks to the whole XSpec team! Regards,
--
Florent Georges
http://fgeorges.org/
http://h2oconsulting.be/
Hi,
> I downloaded XSpec 3 but I can't get it to work - it can't seem to
> find half the stylesheets used for producing the reports.
Mmh, quite weird. The structure of the delivery has changed between
0.2 and 0.3.0. The stylesheets to format the report to HTML are in
xspec-0.3.0/src/reporter/. The main stylesheets to "compile" the
XSpec test suites to either XSLT or XQuery are in
xspec-0.3.0/src/compiler/.
Unless you describe your problem more precisely, I'm afraid we don't
have enough information to solve it.
Thanks for your email, regards,
Hi,
> If I run xspec2 I have no problems, but v3 can't seem to find
> generate-xspec-tests.xsl nor format-xspec-report.xsl.
It seems you found a bug in 0.3.0. As the changes in structure
happended not a long time before the release, and I have no
Windows machine to test the Batch script, I missed some changes
in the Batch script regarding the relative paths between the
script and the stylesheets.
Can you please try to change the following paths:
%~dp0\generate-xspec-tests.xsl
%~dp0\format-xspec-report.xsl
%~dp0\coverage-report.xsl
into (resp. lines 53, 77 and 85):
%~dp0\..\src\compiler\generate-xspec-tests.xsl
%~dp0\..\src\reporter\format-xspec-report.xsl
%~dp0\..\src\reporter\coverage-report.xsl
That should hopefully solve your problem.
Thanks for your help! Regards,
Hi Kate,
> Yep, that's done the trick - thanks!
Good, I've just checked it in SVN.
> I also put the coverage stylesheet path into quotes (at line
> 85) since I read somewhere that you found you needed the quotes
> at lines 53 and 77.
That's right, I saw it to when looking for the paths.
> What param(s) am I meant to pass to coverage? I can't find
> anything so far that tells me.
Honestly, I never used it myself, and it seems it is not
maintained anymore. Normally you just have to call the script
with an extra param "coverage" at the end of the command line.
But the thing is that it relies on a Java class which is an
implementation of Saxon's TraceListener. The name of this
interface has changed between 9.2 and 9.3 so it is not possible
to have a portable class without knowing the version of Saxon.
Furthermore, the stylesheet that formats the coverage report
uses saxon:line-number() which is not available neither in 9.3
nor 9.2 (I am not sure excatly where it stopped to be available
in the free edition of Saxon, I bet in 9.2 when Saxon B switched
to Saxon HE).
For the first point (the Java class), I guess we can say that
Saxon 9.3 has been out for more than one year now, so it is time
to switch to it. For the second point (the saxon:line-number()),
we need to investigate further and find an alternative (that
could be an extension function as we already depends our own Java
classes for coverage).
Sorry I can't help you more on coverage. Maybe someone else?
If you find anything, we'd be interested to hear about it.