maven.test.skip help request

2005-04-22 Thread phillip rhodes
I am in a quandary.

My junit tests require a database to run.
My hibernate:schema-export task needs to have compiled
java class files to run
My junit tests kick off when I try to compile the java
source files
So there isn't a database for my junit test (or rather
there is an out-of-sync one)

I would like to do the following build steps
(basically have more control over when my tests are
run)
1) compile/war application
2) do a hibernate:schema-export
3) run tests

I understand that I can set the maven.test.skip to
false, but can I set it to true/false willy nilly any
time that I want?  Am I going against the maven
currents by doing it this way?
Thanks!




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



Re: maven.test.skip help request

2005-04-22 Thread Erik Husby
phillip rhodes wrote:
I am in a quandary.
My junit tests require a database to run.
My hibernate:schema-export task needs to have compiled
java class files to run
My junit tests kick off when I try to compile the java
source files
So there isn't a database for my junit test (or rather
there is an out-of-sync one)
I would like to do the following build steps
(basically have more control over when my tests are
run)
1) compile/war application
2) do a hibernate:schema-export
3) run tests
I understand that I can set the maven.test.skip to
false, but can I set it to true/false willy nilly any
time that I want?  Am I going against the maven
currents by doing it this way?
Thanks!

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

Add to your maven.xml
postGoal name=test:prepare-filesystem
   ... jelly code to setup your database ..
/postGoal
This will be run after test has setup the directories but before the 
unit tests are run.

--
Erik Husby
Senior Software Engineer
Broad Institute of MIT and Harvard 
Rm. 2192  320 Charles St, Cambridge, MA 02141-2023
mobile: 781.354.6669, office: 617.258.9227, 
email: [EMAIL PROTECTED]  AIM: ErikAtBroad

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