|
|||||||||
Home >> All >> org >> apache >> struts >> [ action overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |
org.apache.struts.action
Class TestDynaActionForm

java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.apache.struts.action.TestDynaActionFormClass
org.apache.struts.action.TestDynaActionForm
- All Implemented Interfaces:
- junit.framework.Test
- public class TestDynaActionForm
- extends TestDynaActionFormClass
Suite of unit tests for the
org.apache.struts.action.DynaActionForm
class.
Field Summary | |
protected DynaActionForm |
dynaForm
The basic DynaActionForm to use for testing. |
protected org.apache.commons.logging.Log |
log
|
protected ActionMapping |
mapping
Dummy ActionMapping for calls to reset() and validate(). |
protected org.apache.struts.config.ModuleConfig |
moduleConfig
Dummy ModuleConfig for calls to reset() and validate(). |
protected static java.lang.String[] |
properties
The set of property names we expect to have returned when calling getDynaProperties() . |
Fields inherited from class org.apache.struts.action.TestDynaActionFormClass |
beanConfig, dynaClass, dynaProperties |
Fields inherited from class junit.framework.TestCase |
|
Constructor Summary | |
TestDynaActionForm(java.lang.String theName)
Defines the testcase name for JUnit. |
Method Summary | |
static void |
main(java.lang.String[] theArgs)
Start the tests. |
void |
setUp()
Sets up the fixture, for example, open a network connection. |
protected void |
setupComplexProperties()
Set up the complex properties that cannot be configured from the initial value expression. |
static junit.framework.Test |
suite()
|
void |
tearDown()
Tears down the fixture, for example, close a network connection. |
void |
testBeanCreate()
|
void |
testGetDescriptorArguments()
Corner cases on getDynaProperty invalid arguments. |
protected void |
testGetDescriptorBase(java.lang.String name,
java.lang.Class type)
Base for testGetDescriptorXxxxx() series of tests. |
void |
testGetDescriptorBoolean()
Positive getDynaProperty on property booleanProperty . |
void |
testGetDescriptorDouble()
Positive getDynaProperty on property doubleProperty . |
void |
testGetDescriptorFloat()
Positive getDynaProperty on property floatProperty . |
void |
testGetDescriptorInt()
Positive getDynaProperty on property intProperty . |
void |
testGetDescriptorLong()
Positive getDynaProperty on property longProperty . |
void |
testGetDescriptors()
Positive test for getDynaPropertys(). |
void |
testGetDescriptorSecond()
Positive getDynaProperty on property booleanSecond
that uses an "is" method as the getter. |
void |
testGetDescriptorShort()
Positive getDynaProperty on property shortProperty . |
void |
testGetDescriptorString()
Positive getDynaProperty on property stringProperty . |
void |
testGetIndexedArguments()
Corner cases on getIndexedProperty invalid arguments. |
void |
testGetIndexedValues()
Positive and negative tests on getIndexedProperty valid arguments. |
void |
testGetMappedArguments()
Corner cases on getMappedProperty invalid arguments. |
void |
testGetMappedValues()
Positive and negative tests on getMappedProperty valid arguments. |
void |
testGetSimpleArguments()
Corner cases on getSimpleProperty invalid arguments. |
void |
testGetSimpleBoolean()
Test getSimpleProperty on a boolean property. |
void |
testGetSimpleDouble()
Test getSimpleProperty on a double property. |
void |
testGetSimpleFloat()
Test getSimpleProperty on a float property. |
void |
testGetSimpleInt()
Test getSimpleProperty on a int property. |
void |
testGetSimpleLong()
Test getSimpleProperty on a long property. |
void |
testGetSimpleShort()
Test getSimpleProperty on a short property. |
void |
testGetSimpleString()
Test getSimpleProperty on a String property. |
void |
testIndexedInitialize()
|
void |
testMappedContains()
Test contains() method for mapped properties. |
void |
testMappedRemove()
Test remove() method for mapped properties. |
void |
testScalarInitialize()
|
void |
testSetIndexedArguments()
Corner cases on setIndexedProperty invalid arguments. |
void |
testSetIndexedValues()
Positive and negative tests on setIndexedProperty valid arguments. |
void |
testSetMappedValues()
Positive and negative tests on setMappedProperty valid arguments. |
void |
testSetSimpleBoolean()
Test setSimpleProperty on a boolean property. |
void |
testSetSimpleDouble()
Test setSimpleProperty on a double property. |
void |
testSetSimpleFloat()
Test setSimpleProperty on a float property. |
void |
testSetSimpleInt()
Test setSimpleProperty on a int property. |
void |
testSetSimpleLong()
Test setSimpleProperty on a long property. |
void |
testSetSimpleShort()
Test setSimpleProperty on a short property. |
void |
testSetSimpleString()
Test setSimpleProperty on a String property. |
Methods inherited from class org.apache.struts.action.TestDynaActionFormClass |
testClassCreate, testConfigAdd, testConfigCreate, testConfigDuplicate, testConfigInitialValues, testConfigProperties, testConfigRemove |
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 |
moduleConfig
protected org.apache.struts.config.ModuleConfig moduleConfig
- Dummy ModuleConfig for calls to reset() and validate().
dynaForm
protected DynaActionForm dynaForm
- The basic
DynaActionForm
to use for testing.
mapping
protected ActionMapping mapping
- Dummy ActionMapping for calls to reset() and validate().
log
protected org.apache.commons.logging.Log log
properties
protected static final java.lang.String[] properties
- The set of property names we expect to have returned when calling
getDynaProperties()
. You should update this list when new properties are added to TestBean.
Constructor Detail |
TestDynaActionForm
public TestDynaActionForm(java.lang.String theName)
- Defines the testcase name for JUnit.
Method Detail |
main
public static void main(java.lang.String[] theArgs)
- Start the tests.
suite
public static junit.framework.Test suite()
setUp
public void setUp()
- Description copied from class:
junit.framework.TestCase
- Sets up the fixture, for example, open a network connection.
This method is called before a test is executed.
- Overrides:
setUp
in classTestDynaActionFormClass
tearDown
public void tearDown()
- Description copied from class:
junit.framework.TestCase
- Tears down the fixture, for example, close a network connection.
This method is called after a test is executed.
- Overrides:
tearDown
in classTestDynaActionFormClass
testBeanCreate
public void testBeanCreate()
testIndexedInitialize
public void testIndexedInitialize()
testScalarInitialize
public void testScalarInitialize()
testGetDescriptorArguments
public void testGetDescriptorArguments()
- Corner cases on getDynaProperty invalid arguments.
testGetDescriptorBoolean
public void testGetDescriptorBoolean()
- Positive getDynaProperty on property
booleanProperty
.
testGetDescriptorDouble
public void testGetDescriptorDouble()
- Positive getDynaProperty on property
doubleProperty
.
testGetDescriptorFloat
public void testGetDescriptorFloat()
- Positive getDynaProperty on property
floatProperty
.
testGetDescriptorInt
public void testGetDescriptorInt()
- Positive getDynaProperty on property
intProperty
.
testGetDescriptorLong
public void testGetDescriptorLong()
- Positive getDynaProperty on property
longProperty
.
testGetDescriptorSecond
public void testGetDescriptorSecond()
- Positive getDynaProperty on property
booleanSecond
that uses an "is" method as the getter.
testGetDescriptorShort
public void testGetDescriptorShort()
- Positive getDynaProperty on property
shortProperty
.
testGetDescriptorString
public void testGetDescriptorString()
- Positive getDynaProperty on property
stringProperty
.
testGetDescriptors
public void testGetDescriptors()
- Positive test for getDynaPropertys(). Each property name
listed in
properties
should be returned exactly once.
testGetIndexedArguments
public void testGetIndexedArguments()
- Corner cases on getIndexedProperty invalid arguments.
testGetIndexedValues
public void testGetIndexedValues()
- Positive and negative tests on getIndexedProperty valid arguments.
testGetMappedArguments
public void testGetMappedArguments()
- Corner cases on getMappedProperty invalid arguments.
testGetMappedValues
public void testGetMappedValues()
- Positive and negative tests on getMappedProperty valid arguments.
testGetSimpleArguments
public void testGetSimpleArguments()
- Corner cases on getSimpleProperty invalid arguments.
testGetSimpleBoolean
public void testGetSimpleBoolean()
- Test getSimpleProperty on a boolean property.
testGetSimpleDouble
public void testGetSimpleDouble()
- Test getSimpleProperty on a double property.
testGetSimpleFloat
public void testGetSimpleFloat()
- Test getSimpleProperty on a float property.
testGetSimpleInt
public void testGetSimpleInt()
- Test getSimpleProperty on a int property.
testGetSimpleLong
public void testGetSimpleLong()
- Test getSimpleProperty on a long property.
testGetSimpleShort
public void testGetSimpleShort()
- Test getSimpleProperty on a short property.
testGetSimpleString
public void testGetSimpleString()
- Test getSimpleProperty on a String property.
testMappedContains
public void testMappedContains()
- Test
contains()
method for mapped properties.
testMappedRemove
public void testMappedRemove()
- Test
remove()
method for mapped properties.
testSetIndexedArguments
public void testSetIndexedArguments()
- Corner cases on setIndexedProperty invalid arguments.
testSetIndexedValues
public void testSetIndexedValues()
- Positive and negative tests on setIndexedProperty valid arguments.
testSetMappedValues
public void testSetMappedValues()
- Positive and negative tests on setMappedProperty valid arguments.
testSetSimpleBoolean
public void testSetSimpleBoolean()
- Test setSimpleProperty on a boolean property.
testSetSimpleDouble
public void testSetSimpleDouble()
- Test setSimpleProperty on a double property.
testSetSimpleFloat
public void testSetSimpleFloat()
- Test setSimpleProperty on a float property.
testSetSimpleInt
public void testSetSimpleInt()
- Test setSimpleProperty on a int property.
testSetSimpleLong
public void testSetSimpleLong()
- Test setSimpleProperty on a long property.
testSetSimpleShort
public void testSetSimpleShort()
- Test setSimpleProperty on a short property.
testSetSimpleString
public void testSetSimpleString()
- Test setSimpleProperty on a String property.
setupComplexProperties
protected void setupComplexProperties()
- Set up the complex properties that cannot be configured from the
initial value expression.
testGetDescriptorBase
protected void testGetDescriptorBase(java.lang.String name, java.lang.Class type)
- Base for testGetDescriptorXxxxx() series of tests.
|
|||||||||
Home >> All >> org >> apache >> struts >> [ action overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: ![]() ![]() ![]() |
DETAIL: FIELD | CONSTR | METHOD |