In my case I had to test a result of a function that returned a sequence
containing both xs:string and nodes.
My XSLT file contains:
<xsl:variable name="test" as="item()+">
<xsl:variable name="t" as="element()">
<c:expected/>
</xsl:variable>
<xsl:sequence select="'sdfs', $t"/>
</xsl:variable>
<xsl:function name="t:test" as="item()+">
<xsl:variable name="t" as="element()">
<c:actual/>
</xsl:variable>
<xsl:sequence select="'sdfs', $t"/>
</xsl:function>
And the XSPEC file:
<scenario label="Test">
<call function="t:test"/>
<expect select="$test"/>
</scenario>
Executing this test results in:
<x:scenario>
<x:label>Test</x:label>
<x:call function="t:test"/>
<x:result select="('sdfs', xs:anyAtomicType(''))"/>
<x:test successful="false">
<x:label/>
<x:result select="('sdfs', xs:anyAtomicType(''))"/>
<x:expect select="('sdfs', xs:anyAtomicType(''))"/>
</x:test>
</x:scenario>
which doesn't give a hint of what's wrong.
The attached file contains a fixed "test:report-value" template based on
xspec-0.4.0rc1.
Original issue reported on code.google.com by mzhal...@gmail.com on 7 Mar 2013 at 3:29
Original issue reported on code.google.com by
mzhal...@gmail.com
on 7 Mar 2013 at 3:29Attachments: