org.apache.maven.plugin.dependency.its
Class AbstractDependencyPluginITCase

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.codehaus.plexus.PlexusTestCase
              extended by org.apache.maven.plugin.dependency.its.AbstractDependencyPluginITCase
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
DependencyPluginTest

public abstract class AbstractDependencyPluginITCase
extends PlexusTestCase

Version:
$Id: AbstractDependencyPluginITCase.java 556442 2007-07-15 20:20:23Z dantran $
Author:
Brian Fox Copied from the Eclipse AbstractEclipsePluginTestCase v2.4

Field Summary
protected static String ARTIFACT_ID
          Artifact-Id for running test builds.
protected static String GROUP_ID
          Group-Id for running test builds.
protected static File localRepositoryDirectory
          Test repository directory.
protected static File PomFile
          Pom File
protected static String VERSION
          Version under which the plugin was installed to the test-time local repository for running test builds.
 
Fields inherited from class org.codehaus.plexus.PlexusTestCase
basedir, container
 
Constructor Summary
AbstractDependencyPluginITCase()
           
 
Method Summary
protected  void executeMaven(File pom, Properties properties, List<String> goals)
           
protected  void executeMaven(File pom, Properties properties, List<String> goals, boolean switchLocalRepo)
           
protected  File getOutputDirectory(String projectName)
           
protected  String getPluginCLISpecification()
           
protected  org.apache.maven.project.MavenProject readProject(File pom)
           
protected  void setUp()
           
protected  void tearDown()
           
protected  void testProject(String projectName, Properties properties, String goalList)
          Execute the plugin.
protected  void testProject(String projectName, String goalList)
          Execute the plugin with no properties
 
Methods inherited from class org.codehaus.plexus.PlexusTestCase
createContainerInstance, customizeContext, customizeContext, getBasedir, getClassLoader, getConfiguration, getConfiguration, getContainer, getCustomConfiguration, getResourceAsStream, getTestFile, getTestFile, getTestPath, getTestPath, lookup, lookup, release
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

localRepositoryDirectory

protected static File localRepositoryDirectory
Test repository directory.


PomFile

protected static File PomFile
Pom File


GROUP_ID

protected static final String GROUP_ID
Group-Id for running test builds.

See Also:
Constant Field Values

ARTIFACT_ID

protected static final String ARTIFACT_ID
Artifact-Id for running test builds.

See Also:
Constant Field Values

VERSION

protected static final String VERSION
Version under which the plugin was installed to the test-time local repository for running test builds.

See Also:
Constant Field Values
Constructor Detail

AbstractDependencyPluginITCase

public AbstractDependencyPluginITCase()
Method Detail

setUp

protected void setUp()
              throws Exception
Overrides:
setUp in class PlexusTestCase
Throws:
Exception
See Also:
PlexusTestCase.setUp()

tearDown

protected void tearDown()
                 throws Exception
Overrides:
tearDown in class PlexusTestCase
Throws:
Exception
See Also:
PlexusTestCase.tearDown()

testProject

protected void testProject(String projectName,
                           String goalList)
                    throws Exception
Execute the plugin with no properties

Parameters:
projectName - project directory
goalList - comma separated list of goals to execute
Throws:
Exception - any exception generated during test

testProject

protected void testProject(String projectName,
                           Properties properties,
                           String goalList)
                    throws Exception
Execute the plugin.

Parameters:
projectName - project directory
properties - additional properties
goalList - comma separated list of goals to execute
Throws:
Exception - any exception generated during test

getOutputDirectory

protected File getOutputDirectory(String projectName)

executeMaven

protected void executeMaven(File pom,
                            Properties properties,
                            List<String> goals)
                     throws org.apache.maven.shared.test.plugin.TestToolsException,
                            ExecutionFailedException
Throws:
org.apache.maven.shared.test.plugin.TestToolsException
ExecutionFailedException

executeMaven

protected void executeMaven(File pom,
                            Properties properties,
                            List<String> goals,
                            boolean switchLocalRepo)
                     throws org.apache.maven.shared.test.plugin.TestToolsException,
                            ExecutionFailedException
Throws:
org.apache.maven.shared.test.plugin.TestToolsException
ExecutionFailedException

readProject

protected org.apache.maven.project.MavenProject readProject(File pom)
                                                     throws org.apache.maven.shared.test.plugin.TestToolsException
Throws:
org.apache.maven.shared.test.plugin.TestToolsException

getPluginCLISpecification

protected String getPluginCLISpecification()


Copyright © 2002-2011 The Apache Software Foundation. All Rights Reserved.