vmassol     2004/01/16 14:05:00

  Modified:    integration/maven plugin.properties project.xml plugin.jelly
               integration/maven/xdocs changes.xml properties.xml
  Log:
  Added basic support for logging (not tested yet - I've just verified it doesn't 
break the existing samples).
  
  Revision  Changes    Path
  1.12      +5 -0      jakarta-cactus/integration/maven/plugin.properties
  
  Index: plugin.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-cactus/integration/maven/plugin.properties,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- plugin.properties 15 Jan 2004 11:29:54 -0000      1.11
  +++ plugin.properties 16 Jan 2004 22:05:00 -0000      1.12
  @@ -78,6 +78,11 @@
   # in an EAR, etc).
   cactus.war = ${maven.build.dir}/${pom.artifactId}-cactus.war
   
  +# (optional) Location of client and server logging properties file to debug
  +# Cactus tests.
  +# cactus.logging.config.client = ${basedir}/logging_client.properties
  +# cactus.logging.config.server = ${basedir}/logging_server.properties
  +
   # -------------------------------------------------------------------
   # Container-related properties
   # -------------------------------------------------------------------
  
  
  
  1.8       +16 -1     jakarta-cactus/integration/maven/project.xml
  
  Index: project.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-cactus/integration/maven/project.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- project.xml       14 Jan 2004 18:56:32 -0000      1.7
  +++ project.xml       16 Jan 2004 22:05:00 -0000      1.8
  @@ -7,7 +7,7 @@
     <!-- Note: Although we inherit from default-project.xml, we still cannot 
           remove the <currentVersion> tag as this project.xml is parsed at 
           runtime whenever our plugin is called. -->
  -  <currentVersion>1.6dev</currentVersion>
  +  <currentVersion>1.6dev-20040115</currentVersion>
   
     <name>Maven Cactus plugin</name>
     <package>org.apache.cactus.integration.maven</package>
  @@ -101,6 +101,21 @@
         <artifactId>commons-beanutils</artifactId>>
         <version>1.6.1</version>
       </dependency>
  +
  +    <!-- Make sure the correct dependent plugins are used in their versions -->
  +    <dependency>
  +      <groupId>maven</groupId>
  +      <artifactId>maven-ear-plugin</artifactId>
  +      <version>1.3</version>
  +      <type>plugin</type>
  +    </dependency>
  +    <dependency>
  +      <groupId>maven</groupId>
  +      <artifactId>maven-ejb-plugin</artifactId>
  +      <version>1.2</version>
  +      <type>plugin</type>
  +    </dependency>
  +
     </dependencies>
     <build>
       <sourceDirectory>src/main</sourceDirectory>
  
  
  
  1.15      +73 -14    jakarta-cactus/integration/maven/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-cactus/integration/maven/plugin.jelly,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- plugin.jelly      15 Jan 2004 11:29:54 -0000      1.14
  +++ plugin.jelly      16 Jan 2004 22:05:00 -0000      1.15
  @@ -292,12 +292,23 @@
           failureproperty="cactustests.failure"
           printsummary="${cactus.printsummary}">
   
  +      <!-- Configure the cactus task for logging -->
  +      <j:if test="${context.getVariable('cactus.logging.config.client') != null}">
  +        <cactusproperty server="false"
  +            propertiesFile="${cactus.logging.config.client}"/>
  +      </j:if>            
  +      <j:if test="${context.getVariable('cactus.logging.config.server') != null}">
  +        <cactusproperty server="true"
  +            propertiesFile="${cactus.logging.config.server}"/>
  +      </j:if>            
  +
         <ant:classpath>
           <ant:pathelement path="${maven.build.dest}"/>
           <ant:pathelement location="${cactus.target.classes.dir}"/>
           <ant:path refid="maven.dependency.classpath"/>
           <ant:path refid="cactus.classpath"/>
         </ant:classpath>
  +
         <containerset>
   
           <!-- TODO: Find how to set the port for JBoss 3x -->
  @@ -486,17 +497,30 @@
          </j:when>
            
       <j:otherwise>    
  +
         <cactus warfile="${cactus.war}" fork="yes" 
             errorproperty="cactustests.error" 
             failureproperty="cactustests.failure"
             printsummary="${cactus.printsummary}">
  -      <ant:classpath>
  -        <ant:pathelement path="${maven.build.dest}"/>
  -        <ant:pathelement location="${cactus.target.classes.dir}"/>
  -        <ant:path refid="maven.dependency.classpath"/>
  -        <ant:path refid="cactus.classpath"/>
  -      </ant:classpath>
  -      <containerset>
  +
  +        <!-- Configure the cactus task for logging -->
  +        <j:if test="${context.getVariable('cactus.logging.config.client') != null}">
  +          <cactusproperty server="false"
  +              propertiesFile="${cactus.logging.config.client}"/>
  +        </j:if>            
  +        <j:if test="${context.getVariable('cactus.logging.config.server') != null}">
  +          <cactusproperty server="true"
  +              propertiesFile="${cactus.logging.config.server}"/>
  +        </j:if>            
  +
  +        <ant:classpath>
  +          <ant:pathelement path="${maven.build.dest}"/>
  +          <ant:pathelement location="${cactus.target.classes.dir}"/>
  +          <ant:path refid="maven.dependency.classpath"/>
  +          <ant:path refid="cactus.classpath"/>
  +        </ant:classpath>
  +
  +        <containerset>
   
           <!-- TODO: Find how to set the port for JBoss 3x -->
           <jboss3x if="cactus.home.jboss3x"
  @@ -595,11 +619,15 @@
           </weblogic7x>            
   
         </containerset>
  +
         <ant:formatter type="plain" usefile="${cactus.junit.usefile}"/>
         <ant:formatter type="xml"/>
  +
         <!-- Run only a single testcase passed in via -Dtestcase=my.single.TestCase-->
         <ant:test name="${testcase}"/>
  +
        </cactus>
  +
       </j:otherwise>         
      </j:choose>    
     </goal>
  @@ -623,17 +651,30 @@
          </j:when>
            
       <j:otherwise>    
  +
         <cactus warfile="${cactus.war}" fork="yes" 
             errorproperty="cactustests.error" 
             failureproperty="cactustests.failure"
             printsummary="${cactus.printsummary}">
  -      <ant:classpath>
  -        <ant:pathelement path="${maven.build.dest}"/>
  -        <ant:pathelement location="${cactus.target.classes.dir}"/>
  -        <ant:path refid="maven.dependency.classpath"/>
  -        <ant:path refid="cactus.classpath"/>
  -      </ant:classpath>
  -      <containerset>
  +
  +        <!-- Configure the cactus task for logging -->
  +        <j:if test="${context.getVariable('cactus.logging.config.client') != null}">
  +          <cactusproperty server="false"
  +              propertiesFile="${cactus.logging.config.client}"/>
  +        </j:if>            
  +        <j:if test="${context.getVariable('cactus.logging.config.server') != null}">
  +          <cactusproperty server="true"
  +              propertiesFile="${cactus.logging.config.server}"/>
  +        </j:if>            
  +
  +        <ant:classpath>
  +          <ant:pathelement path="${maven.build.dest}"/>
  +          <ant:pathelement location="${cactus.target.classes.dir}"/>
  +          <ant:path refid="maven.dependency.classpath"/>
  +          <ant:path refid="cactus.classpath"/>
  +        </ant:classpath>
  +
  +        <containerset>
   
           <!-- TODO: Find how to set the port for JBoss 3x -->
           <jboss3x if="cactus.home.jboss3x"
  @@ -732,15 +773,19 @@
           </weblogic7x>            
   
         </containerset>
  +
         <ant:formatter type="plain" usefile="${cactus.junit.usefile}"/>
         <ant:formatter type="xml"/>
  +
         <!-- Run all testcases matched via -Dtestmatch=FooTest-->
         <ant:batchtest>
           <ant:fileset dir="${cactus.src.dir}">
             <include name="**/${testmatch}.java"/>
           </ant:fileset>
         </ant:batchtest>
  +
        </cactus>
  +
       </j:otherwise>         
      </j:choose>    
     </goal>
  @@ -814,12 +859,24 @@
       <cactus earfile="${cactus.ear}" fork="yes" 
           errorproperty="cactustests.error" failureproperty="cactustests.failure"
           printsummary="${maven.cactus.printsummary}">
  +
  +      <!-- Configure the cactus task for logging -->
  +      <j:if test="${context.getVariable('cactus.logging.config.client') != null}">
  +        <cactusproperty server="false"
  +            propertiesFile="${cactus.logging.config.client}"/>
  +      </j:if>            
  +      <j:if test="${context.getVariable('cactus.logging.config.server') != null}">
  +        <cactusproperty server="true"
  +            propertiesFile="${cactus.logging.config.server}"/>
  +      </j:if>            
  +
         <ant:classpath>
           <ant:pathelement path="${maven.build.dest}"/>
           <ant:pathelement location="${cactus.target.classes.dir}"/>
           <ant:path refid="maven.dependency.classpath"/>
           <ant:path refid="cactus.classpath"/>
         </ant:classpath>
  +
         <containerset>
   
           <!-- TODO: Find how to set the port for JBoss 3x -->
  @@ -922,11 +979,13 @@
   
         <ant:formatter type="plain" usefile="${cactus.junit.usefile}"/>
         <ant:formatter type="xml"/>
  +
         <ant:batchtest>
           <ant:fileset dir="${cactus.src.dir}"
               includes="${cactus.src.includes}"
               excludes="${cactus.src.excludes}"/>
         </ant:batchtest>
  +
       </cactus>
   
       <!-- TODO: Change the Cactus stylesheet (cactus.jsl) to handle reports
  
  
  
  1.16      +6 -0      jakarta-cactus/integration/maven/xdocs/changes.xml
  
  Index: changes.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-cactus/integration/maven/xdocs/changes.xml,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- changes.xml       15 Jan 2004 12:13:41 -0000      1.15
  +++ changes.xml       16 Jan 2004 22:05:00 -0000      1.16
  @@ -12,6 +12,12 @@
   
       <release version="1.6dev" date="development build of 2004-01-15">
         <action dev="vmassol" type="add">
  +        Added 2 new properties to support debugging Cactus tests:
  +        <code>cactus.logging.config.client</code> and
  +        <code>cactus.logging.config.server</code>. They point to logging
  +        config properties file.
  +      </action>
  +      <action dev="vmassol" type="add">
           Added new optional <code>cactus.src.war</code> and
           <code>cactus.src.ejb</code> properties to specify where to find the
           artifacts to test using Cactus.
  
  
  
  1.15      +20 -0     jakarta-cactus/integration/maven/xdocs/properties.xml
  
  Index: properties.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-cactus/integration/maven/xdocs/properties.xml,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- properties.xml    15 Jan 2004 11:29:54 -0000      1.14
  +++ properties.xml    16 Jan 2004 22:05:00 -0000      1.15
  @@ -221,6 +221,26 @@
               </p>
             </td>
           </tr>
  +        <tr>
  +          <td>cactus.logging.config.client</td>
  +          <td>Yes</td>
  +          <td>
  +            <p>
  +              Location of client logging properties file to debug Cactus tests.
  +              For example <code>cactus.logging.config.client = 
${basedir}/logging_client.properties</code>.
  +            </p>
  +          </td>
  +        </tr>
  +        <tr>
  +          <td>cactus.logging.config.server</td>
  +          <td>Yes</td>
  +          <td>
  +            <p>
  +              Location of server logging properties file to debug Cactus tests.
  +              For example <code>cactus.logging.config.server = 
${basedir}/logging_server.properties</code>.
  +            </p>
  +          </td>
  +        </tr>
         </table>
       </section>
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to