public class PlexusJUnit4TestCase extends Object
Modifier and Type | Field and Description |
---|---|
org.junit.rules.TestName |
testName |
Constructor and Description |
---|
PlexusJUnit4TestCase() |
Modifier and Type | Method and Description |
---|---|
protected org.codehaus.plexus.configuration.PlexusConfiguration |
customizeComponentConfiguration() |
protected void |
customizeContainerConfiguration(org.codehaus.plexus.ContainerConfiguration containerConfiguration)
Allow custom test case implementations do augment the default container configuration before executing tests.
|
protected void |
customizeContext(org.codehaus.plexus.context.Context context) |
static String |
getBasedir() |
protected ClassLoader |
getClassLoader() |
protected InputStream |
getConfiguration() |
protected InputStream |
getConfiguration(String subname) |
protected String |
getConfigurationName(String subname)
Allow the retrieval of a container configuration that is based on the name of the test class being run.
|
protected org.codehaus.plexus.PlexusContainer |
getContainer() |
protected String |
getCustomConfigurationName() |
com.google.inject.Module[] |
getCustomModules()
Allows test to define custom modules.
|
String |
getName() |
protected InputStream |
getResourceAsStream(String resource) |
String |
getTestConfiguration() |
static String |
getTestConfiguration(Class<?> clazz) |
static File |
getTestFile(String path) |
static File |
getTestFile(String basedir,
String path) |
static String |
getTestPath(String path) |
static String |
getTestPath(String basedir,
String path) |
protected <T> T |
lookup(Class<T> componentClass) |
protected <T> T |
lookup(Class<T> componentClass,
String roleHint) |
protected Object |
lookup(String componentKey) |
protected Object |
lookup(String role,
String roleHint) |
protected <T> Map<String,T> |
lookupMap(Class<T> componentClass) |
protected void |
release(Object component) |
void |
setUp() |
protected void |
setupContainer() |
void |
tearDown() |
public org.junit.rules.TestName testName
public PlexusJUnit4TestCase()
protected void setupContainer()
public com.google.inject.Module[] getCustomModules()
protected void customizeContainerConfiguration(org.codehaus.plexus.ContainerConfiguration containerConfiguration)
containerConfiguration
- protected void customizeContext(org.codehaus.plexus.context.Context context)
protected org.codehaus.plexus.configuration.PlexusConfiguration customizeComponentConfiguration()
protected org.codehaus.plexus.PlexusContainer getContainer()
protected InputStream getConfiguration() throws Exception
Exception
protected InputStream getConfiguration(String subname) throws Exception
Exception
protected String getCustomConfigurationName()
protected String getConfigurationName(String subname)
subname
- protected InputStream getResourceAsStream(String resource)
protected ClassLoader getClassLoader()
protected <T> T lookup(Class<T> componentClass, String roleHint) throws Exception
Exception
protected <T> Map<String,T> lookupMap(Class<T> componentClass) throws Exception
Exception
public static File getTestFile(String path)
public static File getTestFile(String basedir, String path)
public static String getTestPath(String path)
public static String getTestPath(String basedir, String path)
public static String getBasedir()
public String getTestConfiguration()
public static String getTestConfiguration(Class<?> clazz)
Copyright © 2003–2024 The Apache Software Foundation. All rights reserved.