Use build directories as parameter.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@162805 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Emmanuel Venisse 2004-06-19 12:12:39 +00:00
parent a607e92a46
commit f00f23e685
1 changed files with 20 additions and 2 deletions

View File

@ -33,6 +33,20 @@ import java.util.List;
* expression="#basedir" * expression="#basedir"
* description="" * description=""
* @parameter * @parameter
* name="classesDirectory"
* type="String"
* required="true"
* validator="validator"
* expression="#project.build.output"
* description=""
* @parameter
* name="testClassesDirectory"
* type="String"
* required="true"
* validator="validator"
* expression="#project.build.testOutput"
* description=""
* @parameter
* name="includes" * name="includes"
* type="String" * type="String"
* required="true" * required="true"
@ -74,6 +88,10 @@ public class SurefirePlugin
String basedir = (String) request.getParameter( "basedir" ); String basedir = (String) request.getParameter( "basedir" );
String classesDirectory = (String) request.getParameter( "classesDirectory" );
String testClassesDirectory = (String) request.getParameter( "testClassesDirectory" );
List includes = (List) request.getParameter( "includes" ); List includes = (List) request.getParameter( "includes" );
List excludes = (List) request.getParameter( "excludes" ); List excludes = (List) request.getParameter( "excludes" );
@ -94,9 +112,9 @@ public class SurefirePlugin
surefireBooter.addClassPathUrl( new File( mavenRepoLocal, "surefire/jars/surefire-1.0.jar" ).getPath() ); surefireBooter.addClassPathUrl( new File( mavenRepoLocal, "surefire/jars/surefire-1.0.jar" ).getPath() );
surefireBooter.addClassPathUrl( new File( basedir, "target/classes" ).getPath() ); surefireBooter.addClassPathUrl( new File( basedir, classesDirectory ).getPath() );
surefireBooter.addClassPathUrl( new File( basedir, "target/test-classes" ).getPath() ); surefireBooter.addClassPathUrl( new File( basedir, testClassesDirectory ).getPath() );
for ( int i = 0; i < classpathElements.length; i++ ) for ( int i = 0; i < classpathElements.length; i++ )
{ {