|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.maven.shared.test.plugin.RepositoryTool
public class RepositoryTool
Tools to access and manage Maven repositories for test builds, including construction of a local repository directory structure.
WARNING: Currently, the createLocalRepositoryFromPlugin
method will not
resolve parent POMs that exist only in your normal local repository, and are not reachable
using the relativePath element. This may result in failed test builds, as one or more of the
plugin's ancestor POMs cannot be resolved.
Field Summary | |
---|---|
static String |
ROLE
|
Constructor Summary | |
---|---|
RepositoryTool()
|
Method Summary | |
---|---|
void |
contextualize(org.codehaus.plexus.context.Context context)
Retrieve the PlexusContainer instance used to instantiate this component. |
org.apache.maven.artifact.repository.ArtifactRepository |
createLocalArtifactRepositoryInstance()
Construct an ArtifactRepository instance that refers to the normal Maven local repository. |
org.apache.maven.artifact.repository.ArtifactRepository |
createLocalArtifactRepositoryInstance(File localRepositoryDirectory)
Construct an ArtifactRepository instance that refers to the test-time Maven local repository. |
void |
createLocalRepositoryFromPlugin(org.apache.maven.project.MavenProject pluginProject,
File targetLocalRepoBasedir)
Install a test version of a plugin - along with its POM, and as many ancestor POMs as can be reached using the <relativePath/> element - to a clean local repository directory for use in test builds. |
File |
findLocalRepositoryDirectory()
Lookup and return the location of the normal Maven local repository. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String ROLE
Constructor Detail |
---|
public RepositoryTool()
Method Detail |
---|
public File findLocalRepositoryDirectory() throws TestToolsException
TestToolsException
public org.apache.maven.artifact.repository.ArtifactRepository createLocalArtifactRepositoryInstance() throws TestToolsException
TestToolsException
public org.apache.maven.artifact.repository.ArtifactRepository createLocalArtifactRepositoryInstance(File localRepositoryDirectory) throws TestToolsException
localRepositoryDirectory
- The location of the local repository to be used for test builds.
TestToolsException
public void createLocalRepositoryFromPlugin(org.apache.maven.project.MavenProject pluginProject, File targetLocalRepoBasedir) throws TestToolsException
WARNING: Currently, this method will not resolve parent POMs that exist only in your normal local repository, and are not reachable using the relativePath element. This may result in failed test builds, as one or more of the plugin's ancestor POMs cannot be resolved.
pluginProject
- targetLocalRepoBasedir
-
TestToolsException
public void contextualize(org.codehaus.plexus.context.Context context) throws org.codehaus.plexus.context.ContextException
contextualize
in interface org.codehaus.plexus.personality.plexus.lifecycle.phase.Contextualizable
org.codehaus.plexus.context.ContextException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |