<?xml version="1.0" encoding="UTF-8" ?>
<document
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:noNamespaceSchemaLocation="xdocs.xsd">

  <properties>
    <title>installation</title>
    <author email="hostlows@users.sf.net">Robert Hostlowsky</author>
  </properties>
  <body>

    <section name="normal use">

      <p>
 Change your ant build file to use junitour: add
      </p>
      <source>
&lt;formatter usefile="true" classname="junitour.UnitourResultFormatter" extension=".xml"/&gt;
&lt;formatter usefile="false" classname="junitour.UnitourSummaryResultFormatter" /&gt;</source>
        to <b>build.xml</b>, an example from the junitour sources:

      <subsection name="use with ant">

        <p>To make use of the junitour lib in your own application, do the following:</p>

        <ol>
          <li>drop the junitour.jar file in your ant lib $ANT_HOME/lib/ directory</li>

          <li>
					make sure that following library is in your ANT's classpath: again: $ANT_HOME/lib/ directory
            <ul>
              <li>junitour.jar (3.8.1)</li>
            </ul>
          This is normally already done, when you already work on junittests in your project ;-)
          </li>

          <li>
            example ant build file:
              <source>
&lt;target name="internal-test" depends="compile-tests"&gt;
  &lt;mkdir dir="${testreportdir}"&gt;
  &lt;/mkdir&gt;
  &lt;junit dir="./" failureproperty="test.failure" fork="true" haltonerror="false"&gt;
    &lt;sysproperty key="basedir" value="."&gt;
    &lt;/sysproperty&gt;
    &lt;formatter usefile="true" classname="junitour.UnitourResultFormatter" extension=".xml"&gt;
    &lt;/formatter&gt;
    &lt;formatter usefile="false" classname="junitour.UnitourSummaryResultFormatter"&gt;&lt;/formatter&gt;
    &lt;!--      &lt;formatter usefile="false" type="plain"&gt; &lt;/formatter&gt;--&gt;
    &lt;classpath&gt;
      &lt;fileset dir="${libdir}"&gt;
        &lt;include name="*.jar"&gt;
        &lt;/include&gt;
      &lt;/fileset&gt;
      &lt;pathelement path="${testclassesdir}"&gt;
      &lt;/pathelement&gt;
      &lt;pathelement path="${classesdir}"&gt;
      &lt;/pathelement&gt;
    &lt;/classpath&gt;
    &lt;batchtest todir="${testreportdir}"&gt;
      &lt;fileset dir="${basedir}\src\java\test"&gt;
        &lt;include name="**/*Test.java"&gt;
        &lt;/include&gt;
      &lt;/fileset&gt;
    &lt;/batchtest&gt;
  &lt;/junit&gt;
&lt;/target&gt;</source>
          </li>

          <li>copy the new <a 
          href="http://junitour.svn.sourceforge.net/viewvc/*checkout*/junitour/trunk/junitour/junitour/conf/junit_noframes.xsl">
          junit_noframes.xsl</a> 
           into the /conf/ directory </li>
          <li>use the extended styles for junit-report-generation:
          <source>
&lt;junitreport todir="${testreportdir}" &gt;
  &lt;fileset dir="${testreportdir}" &gt;
      &lt;include name="TEST-*.xml"/&gt;
  &lt;/fileset&gt;
  &lt;report format="noframes" styledir="${basedir}/conf" todir="${docdir}" /&gt;
&lt;/junitreport&gt; </source>
          </li>
        </ol>

      </subsection>

      <p> For more help with using ant in general, please see:
        <a href="http://ant.apache.org/">
          http://ant.apache.org/
        </a>
      </p>

    </section>

  </body>
</document>
