http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2338

*** shadow/2338 Tue Jun 26 13:50:46 2001
--- shadow/2338.tmp.11739       Tue Jun 26 13:50:46 2001
***************
*** 0 ****
--- 1,78 ----
+ +============================================================================+
+ | test copy09 fails                                                          |
+ +----------------------------------------------------------------------------+
+ |        Bug #: 2338                        Product: XalanJ2                 |
+ |       Status: NEW                         Version: 2.0.0                   |
+ |   Resolution:                            Platform: All                     |
+ |     Severity: Normal                   OS/Version: All                     |
+ |     Priority: Other                     Component: org.apache.xalan.xsltc  |
+ +----------------------------------------------------------------------------+
+ |  Assigned To: [EMAIL PROTECTED]                                     |
+ |  Reported By: [EMAIL PROTECTED]                                          |
+ |      CC list: Cc:                                                          |
+ +----------------------------------------------------------------------------+
+ |          URL:                                                              |
+ +============================================================================+
+ |                              DESCRIPTION                                   |
+ Test copy09 fails. It does copy-of on an XML document with nodes that have
+ namespace attributes, but doesn't correctly copy the namespace nodes.
+ 
+ XML file
+ =============================
+ <?xml version="1.0" encoding="UTF-8"?>
+ <root xmlns:ped="http://ped.test.com";>
+    <Out xmlns:ns0="http://www.ns0.com"; ns0:Attr0="Hello" xmlns:ns1="www.ns1.com"
+ ns1:Attr1="Whatsup" ped:Attr2="Goodbye"/>
+    <Out2 xmlns:bdd="http://bdd.test.com";>
+       <Out3 xmlns:jad="http://jad.test.com"/>
+    </Out2>
+ </root>
+ 
+ XSL file
+ ========
+ <?xml version="1.0"?>
+ <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0">
+ 
+ <xsl:output indent="yes"/>
+ 
+   <!-- FileName: copy09 -->
+   <!-- Document: http://www.w3.org/TR/xslt -->
+   <!-- DocVersion: 19991116 -->
+   <!-- Section: 11.3 -->
+   <!-- Purpose: Test for xsl:copy-of with nodeset. -->                
+ 
+ <xsl:template match="/">
+   <root>
+         <xsl:apply-templates/>
+   </root>
+ </xsl:template>
+ 
+ <xsl:template match="*">
+         <xsl:copy-of select="*|@*"/>
+ </xsl:template>
+ 
+ </xsl:stylesheet>
+ 
+ Expected Output
+ ===============
+ <?xml version="1.0" encoding="utf-8"?>
+ <root>
+    <Out xmlns:ns0="http://www.ns0.com"; xmlns:ns1="www.ns1.com"
+ xmlns:ped="http://ped.test.com"; ns0:Attr0="Hello" ns1:Attr1="Whatsup"
+ ped:Attr2="Goodbye"/>
+    <Out2 xmlns:bdd="http://bdd.test.com"; xmlns:ped="http://ped.test.com";>
+       
+       <Out3 xmlns:jad="http://jad.test.com"/>
+    
+    </Out2>
+ </root> 
+ 
+ XSLTC Output
+ ============
+ <?xml version="1.0" encoding="utf-8" ?>
+ <root>
+   <Out xmlns:ns1="www.ns1.com" xmlns:ns0="http://www.ns0.com"; ns0:Attr0="Hello"
+ ns1:Attr1="Whatsup" ns2:Attr2="Goodbye" xmlns:ns2="http://ped.test.com"/> 
+ <Out2>
+           <Out3/>
+      </Out2></root>
\ No newline at end of file

Reply via email to