[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

FW: XSLT 2.0 unit testing utility (Jeni Tennison's te

Subject: FW: XSLT 2.0 unit testing utility (Jeni Tennison's templates)
From: "Weston, Toby" <toby.weston@xxxxxxxxx>
Date: Tue, 21 Mar 2006 11:43:58 -0000
xslt unit test
Hi Folks,

Bit of a XSLT newbie here, so it may be really obvious but...
 
I've been looking at Jeni Tennison's XSLT unit testing templates
(http://www.jenitennison.com/xslt/utilities/unit-testing
<http://www.jenitennison.com/xslt/utilities/unit-testing> )  and in the
absence of a sample file, tried to use the sample square function from the
site. However, I get the following error;
 
Running Tests...
Error at xsl:when on line 382 of
file:/D:/temp/tennison/generate-tests-utils.xsl:
  XPST0003: XPath syntax error at char 19 on line 382 in {$value instance of
void()}:
    Expected type name in SequenceType, found <function>(
Input regex: '
Output regex: '
Failed to compile stylesheet. 1 error detected.
 
It seems to have a problem with generate-tests-utils (line 381); 
 
...
            <xsl:when test="$value instance of void()">()</xsl:when> <!--
this is the offending line! -->
...
 
If I comment the line out, it works fine. I'm using Saxon 8.7 and not 8.4B
as mentioned on the site.
 
The template i'm testing looks like this.
 
<xsl:stylesheet version="2.0"  ... >
<test:tests>
  <test:test>
    <test:param name="number" select="2" />
    <test:expect select="4"/>
  </test:test>
</test:tests>
<xsl:function name="eg:square" as="xs:double">
  <xsl:param name="number" as="xs:double" />
  <xsl:sequence select="$number * $number" />
</xsl:function>
</xsl:stylesheet>
 
Thanks in advance for any pointers.
 
Cheers,
Toby

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.