ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Les Hughes <leslie.hug...@rubus.com>
Subject RE: <wlrun> and j2eeunit
Date Fri, 26 Jan 2001 09:03:02 GMT

Hi,

Since our whole build process is kicked from cron, and wrapped in a shell
script I simply use a build.xml ,check the Ant exit code, call the
startWeblogic.sh script, wait a few seconds and then run a test.xml all from
the master build.sh script.

Simple eh?

Les




> -----Original Message-----
> From: azalmagr@ThoughtWorks.com [mailto:azalmagr@ThoughtWorks.com]
> Sent: 25 January 2001 17:00
> To: ant-user@jakarta.apache.org
> Subject: Re: <wlrun> and j2eeunit
> 
> 
> 
> Hello:
> 
> Micheal Fortson wrote:
> > Does anyone have any examples of starting weblogic (5.1) 
> from ant using
> > <wlrun> in order to run unit tests (say, with junit + 
> j2eeunit) against
> it
> > during the build?
> 
> yeah, we're doing it here, but i had to make some 
> modifications to wlrun
> and create a new task called "sleep".  i've attached these below.  our
> version of wlrun now has a runInNewThread attribute to start 
> the task in a
> new thread.  the only issue that i'm aware of is that the outputs from
> weblogic and junit are intertwined while both tasks are 
> running. (which
> really is fine, since the junit task will write out it's own 
> results to a
> file)  i'm sleeping after the <wlstop> so that we get all the weblogic
> shutdown messages before the build is officially completed.
> 
> caveat:  haltonerror or haltonfailure in junit will end the 
> build right
> there, and won't allow you to properly shutdown the server.
> 
> comments/suggestions?
> 
> 
> Best Wishes,
> alden almagro
> ThoughtWorks, Inc.
> 
> 
> 
> Usage: (i've stripped out the usual attributes for readability)
> 
>    <target name="runtests">
>       <wlrun runInNewThread="true" .../>
>       <sleep seconds="120"/>
> 
>       ...run junit tests against the deployed application
> 
>       <wlstop .../>
>       <sleep seconds="30"/>
>    </target>
> 
> 
> (See attached file: Sleep.java)(See attached file: WLRun.java)
> 

Mime
View raw message