dmarston 2002/11/07 12:18:47 Added: test/tests/conf/position position110.xsl position106.xsl position107.xml position107.xsl position108.xml position108.xsl position109.xml position109.xsl position110.xml position106.xml Log: More coverage of last() and uncoverage of bugs (#14368). Revision Changes Path 1.1 xml-xalan/test/tests/conf/position/position110.xsl Index: position110.xsl =================================================================== <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <!-- FileName: position101 --> <!-- Document: http://www.w3.org/TR/xpath --> <!-- DocVersion: 19991116 --> <!-- Section: 4.1 --> <!-- Creator: David Marston --> <!-- Purpose: Test for last() on 'following::' axis. --> <xsl:output method="xml" encoding="UTF-8" indent="no"/> <xsl:template match="/"> <out> <xsl:for-each select="//center"> <xsl:value-of select="name(following::*[last()])"/> </xsl:for-each> </out> </xsl:template> </xsl:stylesheet> 1.1 xml-xalan/test/tests/conf/position/position106.xsl Index: position106.xsl =================================================================== <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <!-- FileName: position106 --> <!-- Document: http://www.w3.org/TR/xpath --> <!-- DocVersion: 19991116 --> <!-- Section: 4.1 --> <!-- Creator: David Marston --> <!-- Purpose: Test for last() on 'ancestor-or-self::' axis. --> <xsl:output method="xml" encoding="UTF-8" indent="no"/> <xsl:template match="/"> <out> <xsl:for-each select="//center"> <xsl:if test="generate-id(ancestor-or-self::node()[last()])=generate-id(/)">Success</xsl:if> </xsl:for-each> </out> </xsl:template> </xsl:stylesheet> 1.1 xml-xalan/test/tests/conf/position/position107.xml Index: position107.xml =================================================================== <?xml version="1.0" encoding="UTF-8"?> <doc> <north-west1/> <north-west2/> <north/> <north-east1/> <north-east2/> </doc> 1.1 xml-xalan/test/tests/conf/position/position107.xsl Index: position107.xsl =================================================================== <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <!-- FileName: position107 --> <!-- Document: http://www.w3.org/TR/xpath --> <!-- DocVersion: 19991116 --> <!-- Section: 4.1 --> <!-- Creator: David Marston --> <!-- Purpose: Test for last() on 'preceding-sibling::' axis. --> <xsl:output method="xml" encoding="UTF-8" indent="no"/> <xsl:template match="/"> <out> <xsl:apply-templates select="/doc/north"/> </out> </xsl:template> <xsl:template match="north"> <xsl:text>last preceding: </xsl:text> <xsl:value-of select="name(preceding-sibling::*[last()])"/> </xsl:template> </xsl:stylesheet> 1.1 xml-xalan/test/tests/conf/position/position108.xml Index: position108.xml =================================================================== <?xml version="1.0" encoding="UTF-8"?> <doc> <north-west1/> <north-west2/> <north/> <north-east1/> <north-east2/> </doc> 1.1 xml-xalan/test/tests/conf/position/position108.xsl Index: position108.xsl =================================================================== <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <!-- FileName: position108 --> <!-- Document: http://www.w3.org/TR/xpath --> <!-- DocVersion: 19991116 --> <!-- Section: 4.1 --> <!-- Creator: David Marston --> <!-- Purpose: Test for last() on 'following-sibling::' axis. --> <xsl:output method="xml" encoding="UTF-8" indent="no"/> <xsl:template match="/"> <out> <xsl:apply-templates select="/doc/north"/> </out> </xsl:template> <xsl:template match="north"> <xsl:text>last following: </xsl:text> <xsl:value-of select="name(following-sibling::*[last()])"/> </xsl:template> </xsl:stylesheet> 1.1 xml-xalan/test/tests/conf/position/position109.xml Index: position109.xml =================================================================== <?xml version="1.0" encoding="UTF-8"?> <far-north> <north-west1/> <north-west2/> <north> <near-north> <far-west/> <west/> <near-west/> <center> <near-south> <south> <far-south/> </south> </near-south> </center> <near-east/> <east/> <far-east/> </near-north> </north> <north-east1/> <north-east2/> </far-north> 1.1 xml-xalan/test/tests/conf/position/position109.xsl Index: position109.xsl =================================================================== <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <!-- FileName: position109 --> <!-- Document: http://www.w3.org/TR/xpath --> <!-- DocVersion: 19991116 --> <!-- Section: 4.1 --> <!-- Creator: David Marston --> <!-- Purpose: Test for last() on 'preceding::' axis. --> <xsl:output method="xml" encoding="UTF-8" indent="no"/> <xsl:template match="/"> <out> <xsl:for-each select="//center"> <xsl:value-of select="name(preceding::*[last()])"/> </xsl:for-each> </out> </xsl:template> </xsl:stylesheet> 1.1 xml-xalan/test/tests/conf/position/position110.xml Index: position110.xml =================================================================== <?xml version="1.0" encoding="UTF-8"?> <far-north> <north-west1/> <north-west2/> <north> <near-north> <far-west/> <west/> <near-west/> <center> <near-south> <south> <far-south/> </south> </near-south> </center> <near-east/> <east/> <far-east/> </near-north> </north> <north-east1/> <north-east2/> </far-north> 1.1 xml-xalan/test/tests/conf/position/position106.xml Index: position106.xml =================================================================== <?xml version="1.0" encoding="UTF-8"?> <far-north> <north> <near-north> <far-west/> <west/> <near-west/> <center> <near-south> <south> <far-south/> </south> </near-south> </center> <near-east/> <east/> <far-east/> </near-north> </north> </far-north>
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]