On Mon, Jan 12, 2009 at 6:37 AM, Ben Avery <[email protected]> wrote:
> so I have created a functional-testing module, which contains the tests, but > the tests have dependencies on classes in the other modules. I have listed > the [war] modules as dependencies of the funtional test pom, but the compile > phase > fails, as it can't see these classes. if I rig the build to compile the > modules as jars instead, the compilation succeeds (but obviously the tests > can't run, as I need wars to be deployed). This is expected. Java has no concept of a war file on the classpath. (It expects the directory structure to start at the root of the file, it doesn't know to look down under WEB-INF/classes.) A couple of options - move the classes out to a separate module and build a jar from that, which would then be a "normal" dependency for both the war and the tests, or - configure the war plugin to 'attach' the classes as a jar artifact in addition to the war, so you can depend on the jar from other projects. -- Wendy --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
