Class ComponentTestTool
java.lang.Object
org.apache.maven.shared.test.plugin.ComponentTestTool
Deprecated.
Test tool that provides a single point of access for staging a maven component artifact - along with its
POM lineage - into a clean test-time local repository. This involves modifying the component POM to
provide a stable test-time version for test-build POMs to reference, then installing the component
jar and associated POMs (including those ancestors that are reachable using <relativePath>)
into the test local repository.
WARNING: Currently, the RepositoryTool
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
component's ancestor POMs cannot be resolved.
- Version:
- $Id$
- Author:
- jdcasey
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprepareComponentForIntegrationTesting
(File pomFile, String testVersion) Deprecated.Stage the component, using a stable version, into a temporary local-repository directory that is generated by this method.prepareComponentForIntegrationTesting
(File pomFile, String testVersion, File localRepositoryDir) Deprecated.Stage the component, using a stable version, into the specified local-repository directory.prepareComponentForUnitTestingWithMavenBuilds
(File pomFile, String testVersion) Deprecated.Stage the component, using a stable version, into a temporary local-repository directory that is generated by this method.prepareComponentForUnitTestingWithMavenBuilds
(File pomFile, String testVersion, File localRepositoryDir) Deprecated.Stage the component, using a stable version, into the specified local-repository directory.
-
Field Details
-
ROLE
Deprecated.Plexus role
-
-
Constructor Details
-
ComponentTestTool
public ComponentTestTool()Deprecated.
-
-
Method Details
-
prepareComponentForIntegrationTesting
public File prepareComponentForIntegrationTesting(File pomFile, String testVersion) throws TestToolsException Deprecated.Stage the component, using a stable version, into a temporary local-repository directory that is generated by this method. When the component is staged, return the local repository base directory for use in test builds.- Parameters:
pomFile
- current POM filetestVersion
- The test version for the component, used for reference in test-build POMs and fully-qualified goals- Returns:
- The base-directory location of the generated local repository
- Throws:
TestToolsException
- if any
-
prepareComponentForUnitTestingWithMavenBuilds
public File prepareComponentForUnitTestingWithMavenBuilds(File pomFile, String testVersion) throws TestToolsException Deprecated.Stage the component, using a stable version, into a temporary local-repository directory that is generated by this method. When the component is staged, return the local repository base directory for use in test builds. This method also skips unit testing during component jar production, since it is assumed that executing these tests would lead to a recursive test-and-build loop.- Parameters:
pomFile
- current POM filetestVersion
- The test version for the component, used for reference in test-build POMs and fully-qualified goals- Returns:
- The base-directory location of the generated local repository
- Throws:
TestToolsException
- if any
-
prepareComponentForIntegrationTesting
public File prepareComponentForIntegrationTesting(File pomFile, String testVersion, File localRepositoryDir) throws TestToolsException Deprecated.Stage the component, using a stable version, into the specified local-repository directory. When the component is staged, return the local repository base directory for verification.- Parameters:
pomFile
- current POM filetestVersion
- The test version for the component, used for reference in test-build POMs and fully-qualified goalslocalRepositoryDir
- The base-directory location of the test local repository, into which the component's test version should be staged.- Returns:
- The base-directory location of the generated local repository
- Throws:
TestToolsException
- if any
-
prepareComponentForUnitTestingWithMavenBuilds
public File prepareComponentForUnitTestingWithMavenBuilds(File pomFile, String testVersion, File localRepositoryDir) throws TestToolsException Deprecated.Stage the component, using a stable version, into the specified local-repository directory. When the component is staged, return the local repository base directory for verification. This method also skips unit testing during component jar production, since it is assumed that executing these tests would lead to a recursive test-and-build loop.- Parameters:
pomFile
- current POM filetestVersion
- The test version for the component, used for reference in test-build POMs and fully-qualified goalslocalRepositoryDir
- The base-directory location of the test local repository, into which the component's test version should be staged.- Returns:
- The base-directory location of the generated local repository
- Throws:
TestToolsException
- if any
-