title: Maven: Excluding tests from build
body: <p>I have some classes I'm using as tests in my src/test/java folder of my project. When I run maven using the standard maven compile plugin. Those items are compiled into .class files and are included in the jar where the compiled code is packaged.</p>
  
  <p>I've created these tests for myself to run within eclipse, prior to running maven and building my release. They are just sanity tests and should not be included in the build. I'd rather not put them in a seperate project, because, to me, they make sense here. How can I tell maven that I do not want it to compile/include the files in that directory?</p>
  
  <p>I beleive the maven compiler plugin is generating the jar as follows:</p>
  
  <pre><code>&lt;plugin&gt;
   &lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;
   &lt;configuration&gt;
    &lt;source&gt;1.6&lt;/source&gt;
    &lt;target&gt;1.6&lt;/target&gt;
   &lt;/configuration&gt;
  &lt;/plugin&gt;
  </code></pre>