Issue 64 in xspec: Attempting to test a stylesheet that produces <xsl:text> failes

12 views
Skip to first unread message

xs...@googlecode.com

unread,
Jan 1, 2014, 6:40:01 PM1/1/14
to xspe...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 64 by daniel.s...@gmail.com: Attempting to test a stylesheet that
produces <xsl:text> failes
http://code.google.com/p/xspec/issues/detail?id=64

What steps will reproduce the problem?
1. Create a stylesheet & scenario where the expected output includes
xsl:text eg
<x:scenario label="simple paragraph">
<x:context>
<p>Here is some content</p>
</x:context>
<x:expect label="Correctly formatted as an fo:block">
<fo:block
font-size="12pt"
font-family="Helvetica"
font-weight="normal"
color="#404040"
space-after="6pt"><xsl:text>Here is some
content</xsl:text></fo:block>
</x:expect>
</x:scenario>
2. Run the xspec

What is the expected output? What do you see instead?
Expect: Spec should run
Actual output: Fails to run with messages:
[xslt] Processing ../sample.xspec to ../xspec/resolveVariables.xsl
[xslt] Loading
stylesheet ../xspec/src/compiler/generate-xspec-tests-oxygen.xsl
[xslt] ../xspec/src/compiler/generate-tests-helper.xsl:104: Fatal
Error! Undeclared prefix in element name: o
[xslt] Failed to process ../sample.xspec


What version of the product are you using? On what operating system?
Using the version of xspec bundled with Oxygen XML.

Please provide any additional information below.

Within generate-tests-helper-xsl, I think you need to change 'o' to '__x'
in the following templates:

<xsl:template match="xsl:*" mode="test:create-xslt-generator">
<xsl:element name="__x:{ local-name() }">
<xsl:apply-templates select="@*|node()"
mode="test:create-xslt-generator"/>
</xsl:element>
</xsl:template>

<xsl:template match="@xsl:*" mode="test:create-xslt-generator">
<xsl:attribute name="__x:{ local-name() }" select="."/>
</xsl:template>


--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

xs...@googlecode.com

unread,
Jan 1, 2014, 6:45:03 PM1/1/14
to xspe...@googlegroups.com

Comment #1 on issue 64 by daniel.s...@gmail.com: Attempting to test a
stylesheet that produces <xsl:text> failes
http://code.google.com/p/xspec/issues/detail?id=64

Ahh, it's actually already been fixed - my bad! Just the version with
oxygen is out of date.

https://code.google.com/p/xspec/source/diff?spec=svn244&r=236&format=side&path=/trunk/src/compiler/generate-tests-helper.xsl&old_path=/trunk/src/compiler/generate-tests-helper.xsl&old=229
Reply all
Reply to author
Forward
0 new messages