Nicolas De Loof wrote:

I'd like to test my DAO using dbUnit. I've setup an in memory HSQLDB in the test setUp() and it works fine, but the DB is started and created before every test is run (I'm using fork=true, maybee it can explain ?).

I'd like to setup my build process to startup the HSQLDB as Server in a parallel process and apply the schema as a test pregoal, and stop it as a postGoal. Having this, setUp() should only connect to running DB.

Does anyone use such a build scenario and can share maven.xml ?

Nico.

Hello,

For now on our project, we start a separate maven shell with the following goal :
<goal name="hsql:start-server" description="Starts Hsqldb standalone server">
<echo>Starting HSQLDB Server</echo>
<ant:java classname="org.hsqldb.Server"
classpathref="maven.dependency.classpath"
fork="true">
<arg value="-database.0"/>
<arg value="${maven.hsql.server.database.0}"/>
<arg value="-dbname.0"/>
<arg value="${maven.hsql.server.dbname.0}"/>
</ant:java>
<echo>HSQLDB Server Started</echo>
</goal>


If does work, but has the same workaround you're trying to avoid : a manual "start" operation.

if you find something, please tell.

--
Laurent

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



Reply via email to