Actually, all test classes must be in target/test-classes.

Create a jira issue for this.

Emmanuel

Michael Owen wrote:
Hi,

Firstly, I'm using Maven2.

I'm trying to configure where test classes are placed, and where the test reports are placed. I'm trying to do this by changing my pom.xml file to have:

      <testOutputDirectory>build/testclasses</testOutputDirectory>

and also:

          <plugins>
             <plugin>
               <groupId>org.apache.maven.plugins</groupId>
               <artifactId>maven-surefire-plugin</artifactId>
                <configuration>
                    <classesDirectory>build/classes</classesDirectory>
<reportsDirectory>build/docs/txt/tests</reportsDirectory> <testClassesDirectory>build/testclasses</testClassesDirectory>
                </configuration>
             </plugin>
       </plugins>


When I do this, it compiles the source and test classes fine, but says there no tests to run. It makes the reports directory, but puts nothing in there. When I don't try to configure things, but leave the output directories to the default, things work fine. Any help would be good?

Also, just a couple of little queries too.

1) Can I have better reports generated for the testing? I prefer HTML if that is possible, but anything else would be great, other than text files.

2) If I eventually set the test classes directory to the same directory where normal class files go, when I come to jar the classes up, can I say I only want normal classes to go into the jar (ie. not the test classes), by excluding certain classes by their name?

Many thanks. Your help it much appreciated.

Mike



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





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

Reply via email to