java.lang.Object
junit.framework.Assert
junit.framework.TestCase
com.jcorporate.expresso.services.test.ExpressoTestCase
com.jcorporate.expresso.core.utility.DBToolTests
- All Implemented Interfaces:
- junit.framework.Test
- public class DBToolTests
- extends com.jcorporate.expresso.services.test.ExpressoTestCase
What this does:
Runs DBCreate on the schemas and makes sure that no exceptions are thrown
while creating.
NOTE: Derive a class from this class to test all derived schemas.
| Fields inherited from class com.jcorporate.expresso.services.test.ExpressoTestCase |
|
| Fields inherited from class junit.framework.TestCase |
|
| 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 |
schemaList
protected java.util.Vector schemaList
- Add schemas to this list to verify other schemas
alreadyCleared
private static boolean alreadyCleared
failedOne
private static boolean failedOne
installLog
private com.jcorporate.expresso.kernel.InstallLog installLog
DBToolTests
public DBToolTests(java.lang.String name)
throws java.lang.Exception
main
public static void main(java.lang.String[] args)
throws java.lang.Exception
isAlreadyCleared
protected boolean isAlreadyCleared()
setAlreadyCleared
protected void setAlreadyCleared(boolean newValue)
isFailedOnce
protected boolean isFailedOnce()
setFailedOnce
protected void setFailedOnce(boolean newValue)
suite
public static junit.framework.Test suite()
throws java.lang.Exception
- Creates the test cases. Order is important, thus the manual
creation.
testCreate
public void testCreate()
- Runs the createTables() on the schema list to make sure no exceptions
are getting thrown
testAddingSchemas
public void testAddingSchemas()
- If testing multiple schemas, this will make sure that the schema has
been added to the dbtable when created.
testPopulateTables
public void testPopulateTables()
- Runs the populateTables() on the schema list to make sure no exceptions
are getting thrown
testSetupSecurity
public void testSetupSecurity()
- Runs the setupSecurity() on the schema list to make sure no exceptions
are getting thrown
testSetupConfigValues
public void testSetupConfigValues()
- Runs through setting up the configuration values for a particular schema
testOtherSetups
public void testOtherSetups()
- Runs the othersetups() on the schema list to make sure no exceptions
are getting thrown
testVerify
public void testVerify()
- Call verify on all the dbobjects. Code is borrowed from DBTool
Also checks for unique table names. More than one DBOBject shouldn't be
pointing to the same table name.
testSerialization
public void testSerialization()
- This testcase makes sure that all DBObjects within all the schemas are
serializable. Helps insure that there aren't any special custom "types"
that might be causing troubles.
runThroughSerializer
private com.jcorporate.expresso.core.dbobj.DBObject runThroughSerializer(com.jcorporate.expresso.core.dbobj.DBObject testObject)
throws java.lang.Exception
- Helper functino that serializes a DBOBject to a memory stream and then
reads a new instance out from the stream.
setUp
protected void setUp()
throws java.lang.Exception
- Description copied from class:
com.jcorporate.expresso.services.test.ExpressoTestCase
- Sets up and makes sure that ConfigManager is fully loaded and ready to
go.