|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.faktorips.runtime.test.IpsTest2
org.faktorips.runtime.test.IpsTestCaseBase
org.faktorips.runtime.test.IpsTestCase2
public abstract class IpsTestCase2
An ips test case defines the fixture to run a test. To define an ips test case
1) implement a subclass of IpsTestCase2
2) implement the method getRepository to create the runtime repository
3) implement the method executeBusinessLogic to execute the necessary business actions
4) implement the method executeAsserts to ensure the correct result of the test.
| Constructor Summary | |
|---|---|
IpsTestCase2(String qName)
|
|
| Method Summary | |
|---|---|
protected void |
addExtensionAttribute(IModelObject modelObject,
String attributeName,
Object value)
Adds a extension attribute value identified by the attribute name and the test object the attribute is related to. |
int |
countTestCases()
Returns the number of test cases in this test. |
Object |
getExtensionAttributeValue(IModelObject modelObject,
String attributeName)
Returns the value of the given extension attribute identified by the attribute name and the model object the attribute is related to. |
protected abstract void |
initExpectedResultFromXml(Element resultEl)
Initialized the expected result from the given element. |
void |
initFromXml(Element testCaseEl)
Initialized the input and expected result objects from the xml. |
protected abstract void |
initInputFromXml(Element inputEl)
Initialized the input from the given element. |
String |
toString()
|
| Methods inherited from class org.faktorips.runtime.test.IpsTestCaseBase |
|---|
assertEquals, assertEquals, assertEquals, assertEqualsIgnoreScale, assertEqualsIgnoreScale, assertEqualsIgnoreScale, assertFalse, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotNull, assertNull, assertNull, assertNull, assertTrue, assertTrue, assertTrue, executeAsserts, executeBusinessLogic, fail, run |
| Methods inherited from class org.faktorips.runtime.test.IpsTest2 |
|---|
getFullPath, getName, getQualifiedName, getRepository, setFullPath, setRepository |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public IpsTestCase2(String qName)
| Method Detail |
|---|
public final void initFromXml(Element testCaseEl)
protected void addExtensionAttribute(IModelObject modelObject,
String attributeName,
Object value)
protected abstract void initInputFromXml(Element inputEl)
protected abstract void initExpectedResultFromXml(Element resultEl)
public String toString()
toString in class Objectpublic int countTestCases()
IpsTest2
countTestCases in class IpsTest2
public Object getExtensionAttributeValue(IModelObject modelObject,
String attributeName)
null if no such extension
attributes exists.
modelObject - The model object for which the value of the extension attribute should be
returnedattributeName - The name which identifies the extension attribute
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||