I'm having an odd problem with the Maven test plugin. When I run "maven test", the entire project is copied into target/test-classes. If I run "maven test" again, the same happens, including the target directory. After multiple runs, I get a path like this:
<PROJECT_HOME>/target/test-classes/target/test-classes/target/....
Each time it runs, it copies more and more files. Normally, this is okay. However, in a project I'm involved in we have a large source tree with each sub-project inheriting the root projects project.xml. Now the entire source tree gets copied with every run of "maven test". We're talking thousands of files.
Shouldn't "maven test:test-resources" exclude the target/ directory when making a copy? Am I doing something wrong? I suspect that there might be a problem here:
<build>
<sourceDirectory>${basedir}/src/java</sourceDirectory><unitTestSourceDirectory>${basedir}/src/test</unitTestSourceDirectory>
<unitTest>
<includes>
<include>**/*Test.java</include>
</includes>
<resources>
<resource>
<directory>${basedir}</directory>
<include>test.properties</include>
</resource>
</resources>
</unitTest>
</build>If I comment out the <resources/> block, I don't get the copying taking place. How do I specify that I only want the test.properties file to be included?
Thanks,
Marc -- Marcus Christie [EMAIL PROTECTED] | 812-855-4081 http://www.cs.indiana.edu/~machrist Yahoo IM: m_christie | AOL: marcuschristie
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
