You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by an...@apache.org on 2003/11/20 18:00:13 UTC

cvs commit: cocoon-lenya/src/test/anteater tests.xml pubs-default.xml

andreas     2003/11/20 09:00:13

  Modified:    .        build.properties.sample
               src/targets test-build.xml
  Added:       src/test/anteater tests.xml pubs-default.xml
  Log:
  starting anteater tests
  
  Revision  Changes    Path
  1.26      +5 -0      cocoon-lenya/build.properties.sample
  
  Index: build.properties.sample
  ===================================================================
  RCS file: /home/cvs/cocoon-lenya/build.properties.sample,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- build.properties.sample	8 Nov 2003 04:37:26 -0000	1.25
  +++ build.properties.sample	20 Nov 2003 17:00:12 -0000	1.26
  @@ -54,3 +54,8 @@
   # Enable RollingFileAppender of log4j (default is false)
   
   #enable.log4j=true
  +
  +#------------------------------------------------------------------------------------
  +# Anteater home directory
  +
  +#anteater.home=/usr/local/anteater
  
  
  
  1.14      +28 -18    cocoon-lenya/src/targets/test-build.xml
  
  Index: test-build.xml
  ===================================================================
  RCS file: /home/cvs/cocoon-lenya/src/targets/test-build.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- test-build.xml	22 Jul 2003 13:58:52 -0000	1.13
  +++ test-build.xml	20 Nov 2003 17:00:12 -0000	1.14
  @@ -148,22 +148,6 @@
       </java>
     </target>  
   
  -  <!-- Anteater tests  -->
  -  <target name="tests.anteater">
  -    <property name="host" value="localhost"/>
  -    <property name="port" value="8888"/>
  -    <property name="base" value="/"/>
  -
  -    <!-- FIXME: Anteater invocation is platform specific
  -    <exec executable="cmd">
  -      <arg line="/C C:\Java\anteater-0.9.15\bin\anteater.bat -f src/test/anteater/all-tests.xml -Dhost=${host} -Dport=${port} -Dbase=${base}"/>
  -    </exec>
  -    <exec executable="anteater">
  -      <arg line="-f src/test/anteater/all-tests.xml -Dhost=${host} -Dport=${port} -Dbase=${base}"/>
  -    </exec>
  -    -->
  -  </target>
  -
     <!-- Deactivate Document Test -->
     <target name="test.deactivate" depends="test.pub.prepare">
       <java fork="yes" classname="org.apache.lenya.cms.task.DocumentDeactivateTaskTest">
  @@ -172,6 +156,32 @@
         <arg value="${test.pub.id}"/>
         <classpath refid="classpath.default"/>
       </java>
  -  </target>  
  +  </target>
  +
  +  <!-- ================================================ -->
  +  <!-- Anteater tests -->
  +  <!-- ================================================ -->
  +  <target name="tests.anteater">
  +    <property name="anteater.home" value=""/>
  +    <property name="anteater.buildfile" value="src/test/anteater/tests.xml"/>
  +    <java classname="org.apache.tools.ant.Main" fork="true">
  +      <classpath>
  +        <pathelement location="${anteater.home}/resources"/>
  +        <fileset dir="${anteater.home}">
  +          <include name="lib/**/*.jar"/>
  +          <include name="tomcat/**/*.jar"/>
  +        </fileset>
  +      </classpath>
  +      <jvmarg value="-Dant.home=${anteater.home}"/>
  +      <jvmarg value="-Danteater.home=${anteater.home}" />
  +      <jvmarg value="-Danteater.report=${anteater.home}/resources/scripts/report.xml" />
  +      <jvmarg value="-Danteater.resources=${anteater.home}/resources" />
  +      <arg line="-f ${anteater.buildfile}"/>
  +      <arg value="-propertyfile" />
  +      <arg value="${anteater.home}/resources/META-INF/Anteater.properties" />
  +      <!--
  +      <arg value="-Ddefault.debug=10"/>
  +      -->
  +    </java>
  +  </target>
   
  -  
  \ No newline at end of file
  
  
  
  1.1                  cocoon-lenya/src/test/anteater/tests.xml
  
  Index: tests.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <!DOCTYPE project [
    <!ENTITY default          SYSTEM "pubs-default.xml"> 
  ]>
  
  <project name="Lenya Anteater Tests" default="tests">
  
    &default;
    
    <taskdef resource="META-INF/Anteater.tasks"/>
    <typedef resource="META-INF/Anteater.types"/>
  
    <property name="default.port" value="8888"/>
  
    <target name="tests"
      depends="
          pubs.default
      "/>
  
  </project>
  
  
  1.1                  cocoon-lenya/src/test/anteater/pubs-default.xml
  
  Index: pubs-default.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <target name="pubs.default">
    <echo>Testing the default publication</echo>
    
    <property name="publication-id" value="default"/>
    
    <echo>Testing introduction</echo>
    <httpRequest path="/${publication-id}/introduction.html">
      <match>
  <!--      <responseCode value="200"/>-->
        <regexp>Default Publication</regexp>
      </match>
    </httpRequest>
    
  </target>
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-cvs-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-cvs-help@cocoon.apache.org