Wendy,
   How funny to run into you.  I read some of your stuff earlier thanks to
Google.  I was going to do the same thing by requiring Jetty for the test
phase and having an extendable test who's setUp() method would embed a Jetty
instance then deploy the webapp.  I didn't look too far into it but I think
it would work.  I would just need to play around with it.  Knowing I could
do it this way is fine but I was hoping for something more Maven and less
JUnit/Java.  What I mean is you configure everything else in the pom.xml and
I was hoping for something more Maven-like and thus, a solution that would
not require any JUnit/Java magic.  If there is no other option then your
approach and my existing experience with embedding Jetty will come in
handy.  ;)

Take care,

Jeremy

On 6/13/06, Wendy Smoak <[EMAIL PROTECTED]> wrote:

On 6/12/06, Jeremy Whitlock <[EMAIL PROTECTED]> wrote:
>     I would like to know the proper way to run in-container
integration/unit
> tests for applications built/tested using Maven.  I have tried to run
> jetty6:run before the test phase but it does not start as a daemon or
forked
> so Maven never continues to finish running the rest of the lifecycle.  I
> then tried cargo but got the same results.  All I need to do is be able
to
> startup a web container and deploy my war-packaged applications so I can
run
> the integration/unit tests properly using Maven.  Any help would be
highly
> appreciated.

Cargo can do it. :)  It's probably best to ask on the Cargo user list,
but here's a simple example of wrapping tests in a TestSetup class
that starts and stops Tomcat:

<
http://svn.apache.org/repos/asf/struts/action/trunk/integration/apps-it/src/test/java/org/apache/struts/apps/
>

I'm working on a more generic TestSetup class that's controlled by
system properties and can be reused, with the goal of running the same
tests in multiple containers.

--
Wendy

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


Reply via email to