org.codehaus.plexus
Class PlexusTestCase

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.codehaus.plexus.PlexusTestCase
All Implemented Interfaces:
junit.framework.Test

public abstract class PlexusTestCase
extends junit.framework.TestCase

Version:
$Id: PlexusTestCase.java 1708 2005-04-15 04:47:38Z brett $
Author:
Jason van Zyl, Trygve Laugstøl, Michal Maczka

Field Summary
protected  java.lang.String basedir
          Deprecated. Use getBasedir(); instead of accessing this variable directly. When removing this variable rename basedirPath to basedir. Trygve.
protected  PlexusContainer container
           
 
Constructor Summary
PlexusTestCase()
           
PlexusTestCase(java.lang.String testName)
          Deprecated. Use the no arg contstructor.
 
Method Summary
protected  PlexusContainer createContainerInstance()
           
protected  void customizeContext()
           
protected  void customizeContext(Context context)
           
static java.lang.String getBasedir()
           
protected  java.lang.ClassLoader getClassLoader()
           
protected  java.io.InputStream getConfiguration()
           
protected  java.io.InputStream getConfiguration(java.lang.String subname)
           
protected  PlexusContainer getContainer()
           
protected  java.io.InputStream getCustomConfiguration()
           
protected  java.io.InputStream getResourceAsStream(java.lang.String resource)
           
static java.io.File getTestFile(java.lang.String path)
           
static java.io.File getTestFile(java.lang.String basedir, java.lang.String path)
           
static java.lang.String getTestPath(java.lang.String path)
           
static java.lang.String getTestPath(java.lang.String basedir, java.lang.String path)
           
protected  java.lang.Object lookup(java.lang.String componentKey)
           
protected  java.lang.Object lookup(java.lang.String role, java.lang.String id)
           
protected  void release(java.lang.Object component)
           
protected  void setUp()
           
protected  void tearDown()
           
 
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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

container

protected PlexusContainer container

basedir

protected java.lang.String basedir
Deprecated. Use getBasedir(); instead of accessing this variable directly. When removing this variable rename basedirPath to basedir. Trygve.
Constructor Detail

PlexusTestCase

public PlexusTestCase()

PlexusTestCase

public PlexusTestCase(java.lang.String testName)
Deprecated. Use the no arg contstructor.

Method Detail

setUp

protected void setUp()
              throws java.lang.Exception
Overrides:
setUp in class junit.framework.TestCase
Throws:
java.lang.Exception

createContainerInstance

protected PlexusContainer createContainerInstance()

customizeContext

protected void customizeContext()
                         throws java.lang.Exception
Throws:
java.lang.Exception

customizeContext

protected void customizeContext(Context context)
                         throws java.lang.Exception
Throws:
java.lang.Exception

getCustomConfiguration

protected java.io.InputStream getCustomConfiguration()
                                              throws java.lang.Exception
Throws:
java.lang.Exception

tearDown

protected void tearDown()
                 throws java.lang.Exception
Overrides:
tearDown in class junit.framework.TestCase
Throws:
java.lang.Exception

getContainer

protected PlexusContainer getContainer()

getConfiguration

protected java.io.InputStream getConfiguration()
                                        throws java.lang.Exception
Throws:
java.lang.Exception

getConfiguration

protected java.io.InputStream getConfiguration(java.lang.String subname)
                                        throws java.lang.Exception
Throws:
java.lang.Exception

getResourceAsStream

protected java.io.InputStream getResourceAsStream(java.lang.String resource)

getClassLoader

protected java.lang.ClassLoader getClassLoader()

lookup

protected java.lang.Object lookup(java.lang.String componentKey)
                           throws java.lang.Exception
Throws:
java.lang.Exception

lookup

protected java.lang.Object lookup(java.lang.String role,
                                  java.lang.String id)
                           throws java.lang.Exception
Throws:
java.lang.Exception

release

protected void release(java.lang.Object component)
                throws java.lang.Exception
Throws:
java.lang.Exception

getTestFile

public static java.io.File getTestFile(java.lang.String path)

getTestFile

public static java.io.File getTestFile(java.lang.String basedir,
                                       java.lang.String path)

getTestPath

public static java.lang.String getTestPath(java.lang.String path)

getTestPath

public static java.lang.String getTestPath(java.lang.String basedir,
                                           java.lang.String path)

getBasedir

public static java.lang.String getBasedir()


Copyright © 2001-2007 Codehaus. All Rights Reserved.