|
IBM Rational Software Modeler Release 6.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.extensions.TestDecorator
junit.extensions.TestSetup
com.ibm.xtools.patterns.framework.test.AbstractTestSetup
This is the base class for all pattern test setup classes. This class will create a test project with a UML model in the runtime workspace. It will create a package in a class model, and create an instance of the pattern to be tested in the package. All setup classes that extend this class must provide the following information by implementing their corresponding abstract methods: Test Project Name: The name of the Eclipse project used to run the tests. This setup class requires that a modelling project with this name exists in the location of the test plug-in. This project will be copied to the runtime workspace location during setup. Test Target Java Project name: The name of the project where Java classes will be generated to. Test Model Name: Name of the model used to run the tests. Test Case: The test case that this class sets up for.
Nested Class Summary | |
protected class |
AbstractTestSetup.TestPreferences
|
Field Summary |
Fields inherited from class junit.extensions.TestDecorator |
fTest |
Constructor Summary | |
AbstractTestSetup(junit.framework.Test a_test,
ITestDataFactory a_dataFactory,
AbstractTestUtil testUtil)
|
Method Summary | |
void |
cleanTargetJavaProject()
Removes the test package contained in the test Java project. |
static org.eclipse.emf.ecore.EObject |
getFirstRoot(org.eclipse.emf.ecore.resource.Resource resource)
Gets the first root object in the resource. |
AbstractPatternInstance |
getPatternInstance()
|
IParameterDescriptor[] |
getPatternParameters()
|
protected abstract AbstractTestCase |
getTestCase()
|
TestDataManager |
getTestDataManager()
|
protected abstract String |
getTestModelName()
|
org.eclipse.uml2.Package |
getTestPackage()
|
AbstractTestSetup.TestPreferences |
getTestPreferences()
|
protected abstract String |
getTestProjectName()
|
org.eclipse.jdt.core.IJavaProject |
getTestTargetJavaProject()
|
protected abstract String |
getTestTargetJavaProjectName()
|
org.eclipse.uml2.Model |
getUML2Model()
|
protected void |
setUp()
Sets up the fixture. |
protected void |
tearDown()
Tears down the fixture. |
Methods inherited from class junit.extensions.TestSetup |
run |
Methods inherited from class junit.extensions.TestDecorator |
basicRun, countTestCases, getTest, 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 |
Constructor Detail |
public AbstractTestSetup(junit.framework.Test a_test, ITestDataFactory a_dataFactory, AbstractTestUtil testUtil)
Method Detail |
public void cleanTargetJavaProject()
public AbstractPatternInstance getPatternInstance()
protected abstract AbstractTestCase getTestCase()
protected abstract String getTestModelName()
public org.eclipse.uml2.Package getTestPackage()
protected abstract String getTestProjectName()
public org.eclipse.jdt.core.IJavaProject getTestTargetJavaProject()
protected abstract String getTestTargetJavaProjectName()
public org.eclipse.uml2.Model getUML2Model()
public static org.eclipse.emf.ecore.EObject getFirstRoot(org.eclipse.emf.ecore.resource.Resource resource)
resource
- The resource.
protected void setUp() throws Exception
junit.extensions.TestSetup
Exception
TestCase.setUp()
protected void tearDown() throws Exception
junit.extensions.TestSetup
Exception
TestCase.tearDown()
public TestDataManager getTestDataManager()
public IParameterDescriptor[] getPatternParameters()
public AbstractTestSetup.TestPreferences getTestPreferences()
|
IBM Rational Software Modeler Release 6.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2004. All rights reserved.