Why are you excluding things that you need to be in the jar?

Perhaps you can explain your real problem rather than the symptoms.

You are right about the use of the jar.
Where else could it get the classes from? Think about the answer to that one!

Ron

On 20/08/2012 12:38 AM, omritt wrote:
I have a multiple projects where project X is dependent on project Y. The
tests on project X uses project Y which reads a config file. ( X --> Y -->
configfile) I am excluding some configuration files from the JARs using the
maven-jar-plugin.

<plugin>
     <groupId>org.apache.maven.plugins</groupId>
     <artifactId>maven-jar-plugin</artifactId>
     <version>2.3.1</version>
     <inherited>true</inherited>
     <configuration>
         <excludes>
                     <exclude>*.xml</exclude>
                     <exclude>*.*conf*</exclude>
                     <exclude>*.*prop*</exclude>
         </excludes>
     </configuration>
</plugin>

When running "Maven test" on my project everything works well and all test
are successful. But when running "Maven package" project X is failing its
tests because project Y cannot find the config file.

My best guess is that when running the "package" goal, project X runs
against the already built JAR of project Y instead of its .class files. Am I
correct? What can I do to fix this issue?



--
View this message in context: 
http://maven.40175.n5.nabble.com/Test-failures-on-dependent-maven-projects-tp5717563.html
Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]




--
Ron Wheeler
President
Artifact Software Inc
email: [email protected]
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to