src/main/java is the maven recommend directory structure.  This way I can 
so have src/main/resources, both indicating they are belonging to the main
artifact.  It is more organized that way

<unitTestSourceDirectory> can only understand by maven-test-plugin
the real unit test. So if you point it to your main src, your tests will be
automatically invoked after compilation.  and you dont want that.

Last, if you put your integration test cases as the main artifact, then you can
use test:single in maven-test-plugin to invoke your integration.  Be prepare
to dig into maven-test-plugin to understand test:single requirement.
(hmm, perhaps we should start thinking about maven-integration-junit-plugin ;-)

-Dan


On 6/17/05, Craig McDaniel <[EMAIL PROTECTED]> wrote:
> What is the reasoning for the extra "main" level? Why not src/java.
> 
> Also, couldn't you just set the <unitTestSourceDirectory> to
> src/main/java and point <sourceDirectory> someplace empty? I am going
> to be going through this same process soon. Please share what you
> consider to be the best practice here (and why - it really helps to
> understand).
> 
> 
> On 6/17/05, dan tran <[EMAIL PROTECTED]> wrote:
> > Guy,
> >
> > Move your integration/acception test to a separate maven project.
> > Treat it like an application so that you can invoke it on demain.
> > (ie all your test source goto src/main/java....)
> >
> > You many need to write some goal wrapper to invoke the test.
> >
> > -D
> >
> > On 6/17/05, Guy Davis <[EMAIL PROTECTED]> wrote:
> > > Hello,
> > >
> > > I'm currently using Maven 1 for running our regular unit tests.  However
> > > I'm in the process of adding larger acceptance/integration tests that
> > > cover wide areas of functionality.  I am still using the JUnit framework
> > > for these acceptance tests, but I was wondering if there was a way to
> > > separate out these two test types.
> > >
> > > The reason being is the time involved.  The standard unit tests run in
> > > no more than a couple of minutes. However the new acceptance tests
> > > require nearly an hour.
> > >
> > > Ideally, running these acceptance tests would be a different goal
> > > (target).   I'm hoping to configure CruiseControl to run our unit tests
> > > on each build, but only acceptance tests on builds greater than 3 or 4
> > > hours apart.
> > >
> > > Is this possible with Maven?  Perhaps with version 2?  Or does this
> > > require a custom plugin (based on the current unit test plugin)?
> > >
> > > Thanks much,
> > > Guy
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> 
> 
> --
> Craig McDaniel
>

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

Reply via email to