o setting up a base test i will use for all the core components

git-svn-id: https://svn.apache.org/repos/asf/maven/components/branches/MNG-2766@758314 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jason van Zyl 2009-03-25 15:48:51 +00:00
parent a5efa2c5f8
commit a5b9ba4c7d
1 changed files with 4 additions and 23 deletions

View File

@ -5,6 +5,7 @@ import java.util.Arrays;
import java.util.List;
import java.util.Properties;
import org.apache.maven.AbstractCoreMavenComponentTest;
import org.apache.maven.artifact.repository.ArtifactRepository;
import org.apache.maven.execution.DefaultMavenExecutionRequest;
import org.apache.maven.execution.MavenExecutionRequest;
@ -28,14 +29,8 @@ import org.codehaus.plexus.logging.console.ConsoleLogger;
import org.codehaus.plexus.util.FileUtils;
public class LifecycleExecutorTest
extends PlexusTestCase
extends AbstractCoreMavenComponentTest
{
@Requirement
private MavenProjectBuilder projectBuilder;
@Requirement
private RepositorySystem repositorySystem;
@Requirement
private PluginManager pluginManager;
@ -45,9 +40,7 @@ public class LifecycleExecutorTest
protected void setUp()
throws Exception
{
// Components
projectBuilder = lookup( MavenProjectBuilder.class );
repositorySystem = lookup( RepositorySystem.class );
super.setUp();
pluginManager = lookup( PluginManager.class );
lifecycleExecutor = (DefaultLifecycleExecutor) lookup( LifecycleExecutor.class );
}
@ -56,19 +49,7 @@ public class LifecycleExecutorTest
{
return "src/test/projects/lifecycle-executor";
}
protected File getProject( String name )
throws Exception
{
File source = new File( new File( getBasedir(), getProjectsDirectory() ), name );
File target = new File( new File ( getBasedir(), "target" ), name );
if ( !target.exists() )
{
FileUtils.copyDirectoryStructure( source, target );
}
return new File( target, "pom.xml" );
}
// -----------------------------------------------------------------------------------------------
//
// -----------------------------------------------------------------------------------------------