You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Marcin Gurbisz <gu...@poczta.onet.pl> on 2004/12/17 13:39:32 UTC
dealing with integration test
Hi,
My question is how you deal with tests which are integration rather than
simple unit test. For example tests require running server, database
(but they aren't cactus test).
I consider to possibilities:
- creating another module
- creating another dir in existing module (ex. src/integration-test)
In both possibilities I find useful to create plug-in for invoking this
tests.
I will be helpful for any thoughts.
Marcin
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: dealing with integration test
Posted by David Jencks <dj...@gluecode.com>.
There is an existing itest plugin for this purpose. The main example
of its use that I know about is in the openejb project at codehaus.
david jencks
On Dec 17, 2004, at 4:39 AM, Marcin Gurbisz wrote:
> Hi,
>
> My question is how you deal with tests which are integration rather
> than simple unit test. For example tests require running server,
> database (but they aren't cactus test).
> I consider to possibilities:
> - creating another module
> - creating another dir in existing module (ex. src/integration-test)
> In both possibilities I find useful to create plug-in for invoking
> this tests.
> I will be helpful for any thoughts.
>
> Marcin
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: dealing with integration test
Posted by Paul Spencer <pa...@apache.org>.
Marcin,
One idea I have been think about is to have a series of "test only"
projects that test the jar/war of the main project.
Maven Project Description
---------------- -----------------------------------------------------
foo - This project produces foo.jar. The project includes
basic unit testing.
fooUnitTestPart2 - This project produces no jars or wars. It is used
to run additional test on foo.jar. These tests
require that core functionality in the jar/war has
passed all of it's unit test.
fooBasicIntTest - This project produces no jars or wars. It is used
to run basic integrated test on foo.jar.
fooAdvIntTest - This project produces no jars or wars. It is used
to run advanced integrated test on foo.jar
fooComplete - Maven Project that include the above projects as
subproject. Thus building this project will build
foo.jar and run all of the unit and integrated test.
Advantages to this approach
o Allows jar/war to be built with only unit testing being performed.
Test that take a lot of time, due to database setup for example,
are moved out of the main project to a testing project.
o Use of more the one "test only" project allows for more control
over the order test are performed.
o All test can be run using an automated build tool like CruiseControl
and Gump.
Disadvantages to this approach
o A successful build of the main project does not mean that jar/war
has passed all of the test.
Paul Spencer
Marcin Gurbisz wrote:
> Hi,
>
> My question is how you deal with tests which are integration rather than
> simple unit test. For example tests require running server, database
> (but they aren't cactus test).
> I consider to possibilities:
> - creating another module
> - creating another dir in existing module (ex. src/integration-test)
> In both possibilities I find useful to create plug-in for invoking this
> tests.
> I will be helpful for any thoughts.
>
> Marcin
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org