|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object junit.framework.Assert junit.framework.TestCase org.apache.commons.beanutils.DynaBeanUtilsTestCase
public class DynaBeanUtilsTestCase
Test case for BeanUtils when the underlying bean is actually a DynaBean.
Field Summary | |
---|---|
protected DynaBean |
bean
The basic test bean for each test. |
protected String[] |
describes
The set of properties that should be described. |
protected TestBean |
nested
The nested bean pointed at by the "nested" property. |
Constructor Summary | |
---|---|
DynaBeanUtilsTestCase(String name)
Construct a new instance of this test case. |
Method Summary | |
---|---|
protected void |
checkIntArray(int[] actual,
int[] expected)
|
protected void |
checkMap(Map actual,
Map expected)
|
protected static DynaClass |
createDynaClass()
Create and return a DynaClass instance for our test
DynaBean . |
void |
setUp()
Set up instance variables required by this test case. |
static junit.framework.Test |
suite()
Return the tests included in this test suite. |
void |
tearDown()
Tear down instance variables required by this test case. |
void |
testCloneDynaBean()
Test the cloneBean() method from a DynaBean. |
void |
testCopyPropertiesDynaBean()
Test the copyProperties() method from a DynaBean. |
void |
testCopyPropertiesMap()
Test copyProperties() when the origin is a a Map . |
void |
testCopyPropertiesStandard()
Test the copyProperties() method from a standard JavaBean. |
void |
testCopyPropertyByte()
Test narrowing and widening conversions on byte. |
void |
testCopyPropertyDouble()
Test narrowing and widening conversions on double. |
void |
testCopyPropertyFloat()
Test narrowing and widening conversions on float. |
void |
testCopyPropertyInteger()
Test narrowing and widening conversions on int. |
void |
testCopyPropertyLong()
Test narrowing and widening conversions on long. |
void |
testCopyPropertyNestedIndexedArray()
Test copying a property using a nested indexed array expression, with and without conversions. |
void |
testCopyPropertyNestedMappedMap()
Test copying a property using a nested mapped map property. |
void |
testCopyPropertyNestedSimple()
Test copying a property using a nested simple expression, with and without conversions. |
void |
testCopyPropertyNull()
Test copying a null property value. |
void |
testCopyPropertyShort()
Test narrowing and widening conversions on short. |
void |
testDescribe()
Test the describe() method. |
void |
testGetArrayProperty()
tests the string and int arrays of TestBean |
void |
testGetGeneralProperty()
tests getting a 'whatever' property |
void |
testGetIndexedProperty1()
tests getting an indexed property |
void |
testGetIndexedProperty2()
tests getting an indexed property |
void |
testGetNestedProperty()
tests getting a nested property |
void |
testGetSimpleProperty()
tests getting a 'whatever' property |
void |
testPopulateArrayElements()
Test populate() method on individual array elements. |
void |
testPopulateArrayProperties()
Test populate() method on array properties as a whole. |
void |
testPopulateMapped()
Test populate() on mapped properties. |
void |
testPopulateNested()
Test populate() method on nested properties. |
void |
testPopulateScalar()
Test populate() method on scalar properties. |
void |
testSetPropertyNull()
Test setting a null property value. |
void |
testSetPropertyNullValues()
Test calling setProperty() with null property values. |
void |
testSetPropertyOnPrimitiveWrappers()
Test converting to and from primitive wrapper types. |
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 |
---|
protected DynaBean bean
protected TestBean nested
protected String[] describes
Constructor Detail |
---|
public DynaBeanUtilsTestCase(String name)
name
- Name of the test caseMethod Detail |
---|
public void setUp() throws Exception
setUp
in class junit.framework.TestCase
Exception
public static junit.framework.Test suite()
public void tearDown()
tearDown
in class junit.framework.TestCase
public void testCloneDynaBean()
public void testCopyPropertiesDynaBean()
public void testCopyPropertiesMap()
Map
.
public void testCopyPropertiesStandard()
public void testDescribe()
public void testPopulateArrayProperties()
public void testGetArrayProperty()
public void testGetIndexedProperty1()
public void testGetIndexedProperty2()
public void testGetNestedProperty()
public void testGetGeneralProperty()
public void testGetSimpleProperty()
public void testPopulateArrayElements()
public void testPopulateMapped()
public void testPopulateNested()
public void testPopulateScalar()
public void testSetPropertyNullValues() throws Exception
Exception
public void testSetPropertyOnPrimitiveWrappers() throws Exception
Exception
public void testSetPropertyNull() throws Exception
Exception
public void testCopyPropertyByte() throws Exception
Exception
public void testCopyPropertyDouble() throws Exception
Exception
public void testCopyPropertyFloat() throws Exception
Exception
public void testCopyPropertyInteger() throws Exception
Exception
public void testCopyPropertyLong() throws Exception
Exception
public void testCopyPropertyNull() throws Exception
Exception
public void testCopyPropertyShort() throws Exception
Exception
public void testCopyPropertyNestedIndexedArray() throws Exception
Exception
public void testCopyPropertyNestedMappedMap() throws Exception
Exception
public void testCopyPropertyNestedSimple() throws Exception
Exception
protected void checkIntArray(int[] actual, int[] expected)
protected void checkMap(Map actual, Map expected)
protected static DynaClass createDynaClass()
DynaClass
instance for our test
DynaBean
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |