jakarta-cactus-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vincent Massol" <vmas...@pivolis.com>
Subject RE: New <resin2x>/<resin3x> tasks
Date Mon, 14 Jun 2004 05:01:51 GMT


> -----Original Message-----
> From: Matt Raible [mailto:lists@raibledesigns.com]
> Sent: 14 June 2004 10:06
> To: 'Cactus Users List'
> Subject: RE: New <resin2x>/<resin3x> tasks
> 
> 
> 
> > -----Original Message-----
> > From: Vincent Massol [mailto:vmassol@pivolis.com]
> > Sent: Monday, May 31, 2004 2:57 PM
> > To: 'Matt Raible'
> > Cc: 'Cactus Users List'
> > Subject: RE: New <resin2x>/<resin3x> tasks
> >
> > When you say a "runcontainer" task do you mean a task to
> > start/stop a container or to run Cactus tests in it (same as
> > the existing <cactus> task?).
> >
> > I'm asking because the current <cactus> task supports your
> > use case (it has "if" attributes for all containers).
> >
> 
> I dig the <cactus> task, so yes, I'm looking for something like that.
> What I would like is the ability for a user to set a property in
> build.properties and it uses that container for testing.  What I'm
> trying to do is make it as easy as possible for me (and users of
> AppFuse) to switch from Tomcat to Resin to Weblogic or whatever Cactus
> supports.

That's what I'm doing. Except of modifying a property I
comment/uncomment them. However you can easily make it even easier. For
example (not a running example):

container.to.run = tomcat4x

then in your build.xml:

<condition property="should.run.tomcat4x">
  <equals arg1="tomcat4x" arg2="${container.to.run}"/>
</condition>
<condition property="should.run.resin2x">
  <equals arg1="resin2x" arg2="${container.to.run}"/>
</condition>
[...]

And then:

<cactus
[...]
  <resin2x [...] if="should.run.resin2x">
  [...]

> 
> I'm trying to get away from running Servlet/Controller/Action tests
> in-container - so I eventually might not need Cactus there.  However,
I
> test my JSPs with Canoo's WebTest and those will always depend on a
> running container.  Currently, I depend on tomcat.start and
tomcat.stop
> targets that I gathered from Cactus examples.  I'm looking for a
simple
> way to start the container, run the tests, and stop it.  From my
> understanding, the <cactus> task has this built in for most containers
-
> and I'd like to re-use that functionality.
> 

I'd also like to make the Cactus Ant tasks as generic as possible so
that they can be reused in other contexts.

Thanks
-Vincent

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



Mime
View raw message