Hi,

I have been trying for two days to get a nice integration module, but I
have been mostly bumping my head into a thick wall.

My project is a simple EAR (no EJB), that I organized as shown in the
"Better Builds" PDF :


Structure :

foo
        foowar/
                src/
                        main/
                        test/
                pom.xml
        fooear/
                pom.xml
        deploytomcat/
                pom.xml
        integtesttomcat/
                src/
                        it/
                pom.xml
pom.xml


Modules :

Foowar : contains main code, webapp resources and unit tests. Build this
into a war file

Fooear : depends on foowar and wraps the war in a ear (just adding a
META-INF/application.xml)

Deploytomcat : takes the war and deploy it to a tomcat server using
cargo (pretty default 
configuration taken from the cargo tutorial)

Integtesttomcat : comes after deploytomcat in the parent pom "modules"
section, the goal is to run the "test" phase with my integration tests
(using integtesttomcat/src/it). These tests require that the application
is properly deployed, they will basically test the webservices.



My problem is that I can't make these integration tests compile in the
"test" phase of the "integtesttomcat" module. These tests depend on the
classes from foowar/src/main/java (to compile test classes looking like
web services clients, I need the classes defining my model). When I run
the mvn install, the tests will not compile because they will fail to
see the main classes (lots of "Symbol not found")

I have been trying to add the main classes to the test compile by :
- adding my war file as a dependency in the integtestomcat/pom.xml
- adding an outputDirectory in the build section of
integtestomcat/pom.xml (hoping the test compile would add this to the
classpath) : 
        
<outputDirectory>${basedir}/../foowar/src/target</outputDirectory>


I ran out of new ideas a few hours ago, and google, mailinglist archive
and "better builds" did not help me since.

If anyone can take some time to pitch in some suggestions, I would be
very grateful


Thank you all,
Arnaud Jeansen
Ce message et ses pièces jointes (le "message") est destiné à l'usage
exclusif de son destinataire.
Si vous recevez ce message par erreur, merci d'en aviser immédiatement
l'expéditeur  et de le détruire ensuite. Le présent message  pouvant
être altéré à notre insu,  CALYON Crédit Agricole CIB
ne peut pas être engagé par son contenu. Tous droits réservés.

This message and/or any  attachments (the "message") is intended for
the sole use of its addressee.
If you are not the addressee, please immediately notify the sender and
then destroy the message.  As this message and/or any attachments may
have been altered without our knowledge,  its content  is not legally
binding on CALYON Crédit Agricole CIB. All rights reserved.

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

Reply via email to