From: <nw...@us...> - 2007-03-13 12:36:04
|
Revision: 6688 http://svn.sourceforge.net/docbook/?rev=6688&view=rev Author: nwalsh Date: 2007-03-13 05:35:58 -0700 (Tue, 13 Mar 2007) Log Message: ----------- Added tests/unit-tests; added calloutlist.003.xml to the skip list (it intentionally uses a broken IDREF) Modified Paths: -------------- trunk/docbook/relaxng/tools/runtests Added Paths: ----------- trunk/docbook/relaxng/docbook/tests/skip/calloutlist.003.xml trunk/docbook/relaxng/docbook/tests/unit-tests/ trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1589139.xml trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1627845.xml trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1630203.xml Added: trunk/docbook/relaxng/docbook/tests/skip/calloutlist.003.xml =================================================================== --- trunk/docbook/relaxng/docbook/tests/skip/calloutlist.003.xml (rev 0) +++ trunk/docbook/relaxng/docbook/tests/skip/calloutlist.003.xml 2007-03-13 12:35:58 UTC (rev 6688) @@ -0,0 +1,162 @@ +<article xmlns="http://docbook.org/ns/docbook" version="5.0"> + <info><title>Unit Test: calloutlist.003</title> + + <releaseinfo role="CVS">$Id: calloutlist.003.xml 5258 2005-10-12 14:35:03Z xmldoc $</releaseinfo> + <author><personname><firstname>Benoit</firstname><surname>Guillon</surname></personname></author> + </info> + +<section><info><title>Callouts</title></info> + +<section><info><title>Embedded <tag>Co</tag>s</title></info> + +<programlisting> + <refentry> + <info> + <date>2003-10-20</date> <co xml:id="V1690_date-co" linkends="V1690_date"/> + </info> + <refmeta> + <refentrytitle>gtk-options</refentrytitle> <co xml:id="V1690_title-co" linkends="V1690_title"/> + <manvolnum>7</manvolnum> <co xml:id="V1690_manvolnum-co" linkends="V1690_manvolnum"/> + <refmiscinfo class="source-name">GTK+</refmiscinfo> <co xml:id="V1690_source-name-co" linkends="V1690_source-name"/> + <refmiscinfo class="version">1.2</refmiscinfo> <co xml:id="V1690_version-co" linkends="V1690_version"/> + <refmiscinfo class="manual">GTK+ User's Manual</refmiscinfo> <co xml:id="V1690_manual-co" linkends="V1690_manual"/> + </refmeta> + <refnamediv> + <refname>gtk-options</refname> + <refpurpose>Standard Command Line Options for GTK+ Programs</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <para>This manual page describes the command line options, which + are common to all GTK+ based applications.</para> + </refsect1> + </refentry> +</programlisting> + +<calloutlist> + <callout arearefs="V1690_date-co" xml:id="V1690_date"> + <para>Sets the <quote>date</quote> part of the header/footer.</para> + </callout> + <callout arearefs="V1690_title-co" xml:id="V1690_title"> + <para>Sets the <quote>title</quote> part.</para> + </callout> + <callout arearefs="V1690_manvolnum-co" xml:id="V1690_manvolnum"> + <para>Sets the <quote>section</quote> part.</para> + </callout> + <callout arearefs="V1690_source-name-co" xml:id="V1690_source-name"> + <para>Sets the <quote>source name</quote> part.</para> + </callout> + <callout arearefs="V1690_version-co" xml:id="V1690_version"> + <para>Sets the <quote>version</quote> part.</para> + </callout> + <callout arearefs="V1690_manual-co" xml:id="V1690_manual"> + <para>Sets the <quote>manual</quote> part.</para> + </callout> +</calloutlist> + +<para> +Another <tag>screen</tag> including <tag>coref</tag> too. The +first <tag>coref</tag> is not valid, the second one is valid. It checks +also that several items in co/@linkends are correctly handled. +</para> + +<screen> Volume in drive C is SYSTEM Serial number is 2350:717C + Directory of C:\ + +10/17/97 9:04 <DIR> bin +10/16/97 14:11 <DIR> DOS <co xml:id="dos" linkends=" firstco lastco "/> +10/16/97 14:40 <DIR> Program Files +10/16/97 14:46 <DIR> TEMP <coref linkend="unknown"/> +10/17/97 9:04 <DIR> tmp <coref linkend="dos"/> +10/16/97 14:37 <DIR> WINNT +10/16/97 14:25 119 AUTOEXEC.BAT <co linkends="startup" xml:id="autoexec.bat"/> + 2/13/94 6:21 54,619 COMMAND.COM <co linkends="startup" xml:id="command.com"/> +10/16/97 14:25 115 CONFIG.SYS <co xml:id="config.sys"/> +11/16/97 17:17 61,865,984 pagefile.sys + 2/13/94 6:21 9,349 WINA20.386 <co xml:id="wina20.386"/></screen> + +<calloutlist> +<callout arearefs="dos" xml:id="firstco"> + <para> + This directory holds <trademark>MS-DOS</trademark>, the + operating system that was installed before <trademark>Windows + NT</trademark>. + </para> +</callout> +<callout xml:id="startup" arearefs=" autoexec.bat command.com config.sys "> + <para> + System startup code for DOS. + </para> +</callout> +<callout arearefs="wina20.386" xml:id="lastco"> + <para> + Some sort of <trademark>Windows 3.1</trademark> hack for some 386 processors, + as I recall. + </para> +</callout> +</calloutlist> + +</section> + +<section><info><title>Programlistingco</title></info> + +<para>This case checks that spaces are added to reach the expected +column.</para> + +<programlistingco> +<areaspec> +<area xml:id="hermite1" coords="2 55"/> +<area xml:id="hermite2" coords="4 55"/> +</areaspec> +<programlisting> +This is a line +This is another line +This is a third lien + + +... +</programlisting> +<calloutlist> +<callout arearefs="hermite1 hermite2"> +<para> +here <function>HermiteNormalFormIntegerMat</function> +is used +</para> +</callout> +</calloutlist> +</programlistingco> + +<para>This programlistingco checks that you can put several markups at different +column positions into the same line, and that several markups with no column +specification are both put at the end of the line. The special case of a markup at +the end of the last line is checked too.</para> + +<programlistingco> +<areaspec> +<area xml:id="pos10" coords="2 10"/> +<area xml:id="pos12" coords="2 12"/> +<area xml:id="posend1" coords="2"/> +<area xml:id="posend2" coords="2"/> +<area xml:id="poslast" coords="8"/> +</areaspec> +<programlisting> +This is a line +This is another line +This is a third lien + + +... +The very last line</programlisting> +<calloutlist> +<callout arearefs="pos10 pos12"> +<para> +here <function>HermiteNormalFormIntegerMat</function> +is used +</para> +</callout> +</calloutlist> +</programlistingco> + +</section> +</section> +</article> Added: trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1589139.xml =================================================================== --- trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1589139.xml (rev 0) +++ trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1589139.xml 2007-03-13 12:35:58 UTC (rev 6688) @@ -0,0 +1,25 @@ +<book xmlns="http://docbook.org/ns/docbook" + xmlns:xlink="http://www.w3.org/1999/xlink"> +<title>Sample book title</title> + +<chapter> +<title>Sample chapter title</title> + +<para>This unit test contains a <tag>qandaentry</tag> with a <tag>title</tag>, per +<link xlink:href="https://sourceforge.net/tracker/index.php?func=detail&aid=1589139&group_id=21935&atid=384107"/>.</para> + +<qandaset> +<qandaentry> +<title>QandA Entry Title</title> +<question> +<para>What is the question.</para> +</question> +<answer> +<para>I don't know, but the answer is 42.</para> +</answer> +</qandaentry> +</qandaset> + +</chapter> + +</book> Added: trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1627845.xml =================================================================== --- trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1627845.xml (rev 0) +++ trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1627845.xml 2007-03-13 12:35:58 UTC (rev 6688) @@ -0,0 +1,55 @@ +<book xmlns="http://docbook.org/ns/docbook" + xmlns:xlink="http://www.w3.org/1999/xlink"> +<title>Sample book title</title> + +<chapter> +<title>Sample chapter title</title> + +<para>This unit test contains a CALS <tag>table</tag> and a CALS +<tag>informaltable</tag>, each with a <tag>caption</tag>, per +<link xlink:href="https://sourceforge.net/tracker/index.php?func=detail&aid=1627845&group_id=21935&atid=384107"/>. It also contains an HTML +<tag>table</tag> with a <tag>caption</tag> that contains inlines, a decision +reached while resolving the caption RFE.</para> + +<table> +<title>Some table</title> +<tgroup cols="2"> +<tbody> +<row> +<entry>T1.A1</entry> +<entry>T1.A2</entry> +</row> +</tbody> +</tgroup> +<caption> +<para>This is a table caption.</para> +</caption> +</table> + +<informaltable> +<tgroup cols="2"> +<tbody> +<row> +<entry>T2.A1</entry> +<entry>T2.A2</entry> +</row> +</tbody> +</tgroup> +<caption> +<para>This is an informal table caption.</para> +</caption> +</informaltable> + +<table> +<caption>This is an <emphasis>HTML</emphasis> table</caption> +<tbody> +<tr> +<td>T3.A1</td> +<td>T3.A2</td> +</tr> +</tbody> +</table> + +</chapter> + +</book> Added: trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1630203.xml =================================================================== --- trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1630203.xml (rev 0) +++ trunk/docbook/relaxng/docbook/tests/unit-tests/rfe1630203.xml 2007-03-13 12:35:58 UTC (rev 6688) @@ -0,0 +1,14 @@ +<book xmlns="http://docbook.org/ns/docbook" + xmlns:xlink="http://www.w3.org/1999/xlink"> +<title>Sample book title</title> + +<chapter> +<title>Sample chapter title</title> + +<para>This unit test contains an empty <tag>glossary</tag>, per +<link xlink:href="https://sourceforge.net/tracker/index.php?func=detail&aid=1630203&group_id=21935&atid=384107"/>.</para> +</chapter> + +<glossary/> + +</book> Modified: trunk/docbook/relaxng/tools/runtests =================================================================== --- trunk/docbook/relaxng/tools/runtests 2007-03-13 12:34:46 UTC (rev 6687) +++ trunk/docbook/relaxng/tools/runtests 2007-03-13 12:35:58 UTC (rev 6688) @@ -17,30 +17,49 @@ if [ "$XMLFILES" = "" ]; then + if [ -d unit-tests ]; then + for f in unit-tests/*.xml; do + XMLFILES="$XMLFILES `basename $f`" + done + fi + for f in $SRCDIR/*.xml; do XMLFILES="$XMLFILES `basename $f`" done fi for f in $XMLFILES; do + srcfile=$f + if [ -f $SRCDIR/$f ]; then + srcfile=$SRCDIR/$f + elif [ -f unit-tests/$f ]; then + srcfile=unit-tests/$f + fi + REBUILD=1 - if [ ! -f $SRCDIR/$f ]; then + if [ "$f" = "$srcfile" ]; then REBUILD=0 fi - if [ -f $f -a $f -nt $SRCDIR/$f -a $f -nt $DB4UPG ]; then + if [ -f $f -a $f -nt $srcfile -a $f -nt $DB4UPG ]; then REBUILD=0 fi - if [ -f passed/$f -a passed/$f -nt $SRCDIR/$f -a passed/$f -nt $DB4UPG ]; then + if [ -f passed/$f -a passed/$f -nt $srcfile -a passed/$f -nt $DB4UPG ]; then REBUILD=0 fi + if grep -e "xmlns\(:[^=]+\)\?=\(.\)http://docbook.org/ns/docbook\2" $srcfile > /dev/null; then + REBUILD=0 + fi + if [ ! -f skip/$f ]; then if [ "$REBUILD" != "0" ]; then echo -n "Update $f..." - xsltproc --novalid --output $f $DB4UPG $SRCDIR/$f + xsltproc --novalid --output $f $DB4UPG $srcfile + elif [ ! -f $f -a "$f" != "$srcfile" ]; then + cp $srcfile $f fi if [ ! -f passed/$f -o $f -nt passed/$f ]; then This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |