|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.jmock.core.VerifyingTestCase
org.jmock.core.MockObjectSupportTestCase
org.jmock.MockObjectTestCase
com.bm.testsuite.BaseTest
com.bm.testsuite.PoJoFixture
T
- -
the type of the servicepublic abstract class PoJoFixture
Supports entity manager and flat file db injection for pojos.
Field Summary |
---|
Fields inherited from class org.jmock.core.MockObjectSupportTestCase |
---|
ANYTHING, NOT_NULL, NULL |
Constructor Summary | |
---|---|
PoJoFixture(java.lang.Class<?>[] usedEntityBeans)
Constructor. |
|
PoJoFixture(java.lang.Class<?>[] usedEntityBeans,
InitialDataSet... initialData)
Constructor. |
Method Summary | ||
---|---|---|
protected
|
deleteAll(java.lang.Class<T> clazz)
Deletes all rows of the given class in the database. |
|
protected
|
findAll(java.lang.Class<T> clazz)
Find all rows of the given class in the database. |
|
javax.sql.DataSource |
getDataSource()
Liefert die datasource. |
|
javax.persistence.EntityManager |
getEntityManager()
Returns a isntance of a EntityManager. |
|
protected
|
persist(java.util.List<T> complexObjectGraph)
Persists all objects in the database. |
|
protected void |
setUp()
|
|
protected void |
tearDown()
|
Methods inherited from class com.bm.testsuite.BaseTest |
---|
assertCollectionsEqual, assertFalse, assertFalse, assertInstanceOf, assertInstanceOf, setValueForField, testNothing |
Methods inherited from class org.jmock.MockObjectTestCase |
---|
atLeastOnce, defaultMockNameForType, mock, mock, never, newCoreMock, once, onConsecutiveCalls, onConsecutiveCalls, onConsecutiveCalls, returnValue, returnValue, returnValue, returnValue, returnValue, returnValue, returnValue, returnValue, returnValue, throwException |
Methods inherited from class org.jmock.core.MockObjectSupportTestCase |
---|
and, eq, eq, eq, eq, eq, eq, eq, eq, eq, eq, isA, newDummy, newDummy, newDummy, not, or, same, stringContains |
Methods inherited from class org.jmock.core.VerifyingTestCase |
---|
registerToVerify, runBare, unregisterToVerify, verify |
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, createResult, getName, run, run, 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, 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 PoJoFixture(java.lang.Class<?>[] usedEntityBeans)
usedEntityBeans
- -
the used entity beanspublic PoJoFixture(java.lang.Class<?>[] usedEntityBeans, InitialDataSet... initialData)
usedEntityBeans
- -
the used entity beansinitialData
- -
the initial data to create in the dbMethod Detail |
---|
protected void setUp() throws java.lang.Exception
setUp
in class junit.framework.TestCase
java.lang.Exception
TestCase.setUp()
protected <T> java.util.List<T> findAll(java.lang.Class<T> clazz)
T
- the tyme of the persistent objectclazz
- the class of of the persistent object
protected <T> void deleteAll(java.lang.Class<T> clazz)
T
- the tyme of the persistent objectclazz
- the class of of the persistent objectprotected <T> java.util.List<T> persist(java.util.List<T> complexObjectGraph)
T
- the tyme of the persistent objectcomplexObjectGraph
- th egraph to persist
protected void tearDown() throws java.lang.Exception
tearDown
in class junit.framework.TestCase
java.lang.Exception
TestCase.tearDown()
public javax.sql.DataSource getDataSource()
public javax.persistence.EntityManager getEntityManager()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |