buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Odelya Holiday <ode...@alicanto.com>
Subject Re: packaging one project before testing
Date Thu, 16 Aug 2012 17:29:08 GMT
Thanks

But how can I tell buildr which tests are integration and which are simple junit?

In the build file I have more than project definition

Thanks 

Odelya

On Aug 16, 2012, at 8:23 PM, Alex Boisvert <alex.boisvert@gmail.com> wrote:

> You may want to take a look at the integration test feature:
> http://buildr.apache.org/testing.html#integration
> 
> 
> On Thu, Aug 16, 2012 at 7:06 AM, Odelya Holiday <odelya@alicanto.com> wrote:
> 
>> Hi!
>> 
>> I realized, that in buildr by default the order is like this:
>> 
>> build all the projects
>> run tests on all the projects
>> package all the proejcts
>> 
>> The thing is that I need to package the war before running the tests -
>> since they call my api war.
>> 
>> My buildfile is as follows:
>> 
>>         desc 'Building engine project for engine and API'
>>        define 'Engine' do
>>                compile.with  SPRING_CORE,
>> ACTIVATION,ANTLR,AOPALLIANCE,ASM,ASPECTJ
>>                info "package engine jar"
>>                package(:jar, :id=>"Engine")
>>        end
>> 
>>        desc 'Building API project'
>>        define 'MyBuild' do
>>                # specify the artifact for plimus, twilio and floristone
>> since I
>> created it locally
>>                plimus = artifact('plimus.com:
>> plimus:jar:1.0').from('/var/lib/selfdep/wsintegration.jar')
>>                floristone = artifact('floristone.com:
>> floristone:jar:1.0').from('/var/lib/selfdep/floristone.jar')
>>                twilio =  artifact('twilio.com:
>> twilio:jar:1.0').from('/var/lib/selfdep/twilio.jar')
>>                # install the artifact locally
>>                install plimus
>>                install floristone
>>                install twilio
>>                libs =
>> AXIS_SAAJ,RESTFB,SEARCH,SEARCH_HIBERNATE,SLF4J,SLF4J_LOG4J,STAX_API,TWITTER4J_CORE,WSDL4J
>>                compile.with libs
>>                war = package(:war, :id=>"MyBuild")
>>                war.with :libs => libs
>>                package.enhance do
>>                          sh "sudo " + tomcatlocation + "/bin/shutdown.sh"
>> rescue nil
>>                          cp war.to_s, buildrwar
>>                          sh "sudo " + tomcatlocation + "/bin/startup.sh"
>>                 end
>>        end
>> 
>> I would like the package.enhance to happen before invoking the tests
>> of Engine and the tests of the MyBuild (the api) so it could check it
>> while tomcat is running.
>> 
>> How can I do it?
>> --
>> Odelya
>> 

Mime
  • Unnamed multipart/alternative (inline, 7-Bit, 0 bytes)
View raw message