New namespace-alias test (Saxon bug)
authorMichael Kay <mike@saxonica.com>
Mon, 11 Jan 2016 11:29:28 +0000
changeset 1200 6da4ce1bab22
parent 1199 69cf9726a11f
child 1201 5fe86a4739be
New namespace-alias test (Saxon bug)
tests/decl/namespace-alias/_namespace-alias-test-set.xml
tests/decl/namespace-alias/namespace-alias-0902.xsl
--- a/tests/decl/namespace-alias/_namespace-alias-test-set.xml	Mon Jan 11 11:28:21 2016 +0000
+++ b/tests/decl/namespace-alias/_namespace-alias-test-set.xml	Mon Jan 11 11:29:28 2016 +0000
@@ -70,6 +70,21 @@
          <error code="XTSE0010"/>
       </result>
    </test-case>
+   
+   <test-case name="namespace-alias-0902">
+      <description>Saxon bug 2563</description>
+      <created by="John Lumley" on="2016-01-05"/>
+      <dependencies>
+         <spec value="XSLT10+"/>
+      </dependencies>
+      <test>
+         <stylesheet file="namespace-alias-0902.xsl"/>
+         <initial-template name="main"/>
+      </test>
+      <result>
+         <assert-xml><![CDATA[<result xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:attribute/></result>]]></assert-xml>
+      </result>
+   </test-case>
 
    <test-case name="namespace-alias-1001">
       <description>TEST namespace-alias on attribute names BUG Saxon 6.3/013</description>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/decl/namespace-alias/namespace-alias-0902.xsl	Mon Jan 11 11:29:28 2016 +0000
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
+  xmlns:xs="http://www.w3.org/2001/XMLSchema" 
+  xmlns:X="XSL" exclude-result-prefixes="xs" version="3.0">
+  <xsl:namespace-alias stylesheet-prefix="X" result-prefix="xsl"/>
+  <xsl:template name="main">
+    <xsl:variable name="properties" as="item()*">
+      <X:attribute/>
+    </xsl:variable>
+    <result>
+      <xsl:sequence select="$properties"/>
+    </result>
+  </xsl:template>
+</xsl:stylesheet>
\ No newline at end of file