You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cactus-dev@jakarta.apache.org by ji...@apache.org on 2004/04/21 20:40:53 UTC

[jira] Commented: (CACTUS-102) support for maven multiproject plugin

The following comment has been added to this issue:

     Author: Vincent Massol
    Created: Wed, 21 Apr 2004 11:40 AM
       Body:
Hi Nicolas,

Why not do the following instead:

- Create a goal in your top level maven.xml:

<goal name="cactus-run">
  <j:if test="${context.getVariable('maven.multiproject.type')== 'war'}">
    <attainGoal name="cactus"/>
  </j:if>
</goal>

Then you invoke it with:

maven -Dgoal=cactus-run multiproject:goal 

Of course you can make it even more automated by adding the following to maven.xml:

<goal name="multicactus">
  <j:set var="goal" value="cactus-run"/>
  <attainGoal name="multiproject:goal"/>
</goal>

Then typing "maven multicactus" will perform the feat.

We cannot apply your solution as is because you're suggesting to modify the multiproject plugin by introducing a dependency on Cactus. As Cactus is out of the "core" maven plugins, it won't be possible.

Thanks
---------------------------------------------------------------------
View this comment:
  http://issues.apache.org/jira/browse/CACTUS-102?page=comments#action_35190

---------------------------------------------------------------------
View the issue:
  http://issues.apache.org/jira/browse/CACTUS-102

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: CACTUS-102
    Summary: support for maven multiproject plugin
       Type: Improvement

     Status: Unassigned
   Priority: Minor

    Project: Cactus
 Components: 
             Maven Integration

   Assignee: 
   Reporter: nicolas de loof

    Created: Wed, 21 Apr 2004 9:13 AM
    Updated: Wed, 21 Apr 2004 11:40 AM
Environment: maven multiproject

Description:
Hi guys,

Here's a proposal for a new goal on multiproject plugin. It allows to run cactus tests on all sub-projects of "war"
type, the same way junit tests can be run.

I use it from cruisecontrol scripts to update, compile and test my app (having 3 web modules and 4 jars).

Nico.



 <!--====================================================================-->
 <!-- Exécute les test Cactus sur tous les sous-projects de type "war"   -->
 <!--====================================================================-->
 <goal name="multiproject:cactus">
  <maven:reactor basedir="${maven.multiproject.basedir}"
   includes="${maven.multiproject.includes}"
   excludes="${maven.multiproject.excludes}"
   postProcessing="true"
   ignoreFailures="${maven.multiproject.ignoreFailures}" />

  <j:forEach var="reactorProject" items="${reactorProjects}">
   <j:set
    var="type"
    value="${reactorProject.getContext().getVariable('maven.multiproject.type')}"/>
   <j:if test="${type == 'war'}">
    <ant:echo>----------------------------------------------------</ant:echo>
    <ant:echo>Running cactus test for ${reactorProject.artifactId}</ant:echo>
    <ant:echo>----------------------------------------------------</ant:echo>
    <maven:maven
     descriptor="${basedir}/../${reactorProject.artifactId}/project.xml"
     goals="cactus"
     ignoreFailures="${maven.multiproject.ignoreFailures}" />
   </j:if>
  </j:forEach>
 </goal>




---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: cactus-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: cactus-dev-help@jakarta.apache.org