summaryrefslogtreecommitdiff
path: root/tests/general
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2004-04-05 13:26:19 +0000
committerDaniel Veillard <veillard@src.gnome.org>2004-04-05 13:26:19 +0000
commit15bd1ff3088b9d3c6bc2f8bff44c1ea099e0c667 (patch)
tree99417c6dd3d36eb57cd4c28cda2d46f87e3bc0cb /tests/general
parent7c21d685b3fca996c043e9532ae84b6c88757ffb (diff)
downloadlibxslt-15bd1ff3088b9d3c6bc2f8bff44c1ea099e0c667.tar.gz
libxslt-15bd1ff3088b9d3c6bc2f8bff44c1ea099e0c667.tar.bz2
libxslt-15bd1ff3088b9d3c6bc2f8bff44c1ea099e0c667.zip
fixed a stupid cut'npaste bug #139132 added test to the regression for bug
* libxslt/keys.c: fixed a stupid cut'npaste bug #139132 * tests/docs/Makefile.am tests/docs/bug-146.xml tests/general/Makefile.am tests/docs/bug-146*: added test to the regression for bug #139132 Daniel
Diffstat (limited to 'tests/general')
-rw-r--r--tests/general/Makefile.am1
-rw-r--r--tests/general/bug-146.out6
-rw-r--r--tests/general/bug-146.xsl24
3 files changed, 31 insertions, 0 deletions
diff --git a/tests/general/Makefile.am b/tests/general/Makefile.am
index 2d08bee9..4bd304c1 100644
--- a/tests/general/Makefile.am
+++ b/tests/general/Makefile.am
@@ -151,6 +151,7 @@ EXTRA_DIST = \
bug-143.out bug-143.xsl \
bug-144.out bug-144.xsl \
bug-145.out bug-145.xsl bug-145.err \
+ bug-146.out bug-146.xsl \
character.out character.xsl \
character2.out character2.xsl \
itemschoose.out itemschoose.xsl \
diff --git a/tests/general/bug-146.out b/tests/general/bug-146.out
new file mode 100644
index 00000000..d88e13a6
--- /dev/null
+++ b/tests/general/bug-146.out
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="windows-1251"?>
+<root>
+ <colls COL_COD="PT" COL_NAME="Арго" CURR_ID_0="" CURR_ID_1="" CURR_ID_2="" CURR_ID_3="">
+ <color COL_ID="24007" TITLE="пустой" RU_CODE=""/>
+ </colls>
+</root>
diff --git a/tests/general/bug-146.xsl b/tests/general/bug-146.xsl
new file mode 100644
index 00000000..c8f81492
--- /dev/null
+++ b/tests/general/bug-146.xsl
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="windows-1251"?>
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+<xsl:output method="xml" encoding="windows-1251" indent="yes"/>
+<xsl:strip-space elements="*"/>
+<xsl:key name="EMPTY_EN_CODE_COLLS" match="/root/colls/goodcoll/goodcomb/@COL_ID
+[../@EN_CODE = '']" use="../../../@COL_COD"/>
+<xsl:key name="EMPTY_EN_CODE_COLRS" match="/root/colls/goodcoll/goodcomb/@COL_ID
+[../@EN_CODE = '']" use="concat(.,':',../../../@COL_COD)"/>
+<xsl:template match="/">
+<root>
+ <xsl:for-each select="/root/colls[key('EMPTY_EN_CODE_COLLS',@COL_COD)]">
+ <xsl:copy>
+ <xsl:copy-of select="@*"/>
+ <xsl:for-each select="key('EMPTY_EN_CODE_COLLS',@COL_COD)[generate-id(.) =
+generate-id(key('EMPTY_EN_CODE_COLRS',concat(.,':',../../../@COL_COD)))]">
+ <color>
+ <xsl:copy-of select="../@TITLE | ../@RU_CODE | ."/>
+ </color>
+ </xsl:for-each>
+ </xsl:copy>
+ </xsl:for-each>
+</root>
+</xsl:template>
+</xsl:stylesheet>