|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.apache.jdo.tck.JDO_Test
org.apache.jdo.tck.api.persistencemanagerfactory.AbstractGetPMF
org.apache.jdo.tck.api.persistencemanagerfactory.GetPMFByStream
Title:GetPMFByStream of PersistenceManagerFactory
Keywords: persistencemanagerfactory
Assertion IDs: A8.6-17.
Assertion Description:
Uses the parameter(s) passed as arguments to construct a Properties
instance, and then delegates to the static method
getPersistenceManagerFactory in the class named in the property
javax.jdo.PersistenceManagerFactoryClass.
If there are any exceptions while trying to construct the Properties
instance or to call the static method,
then either A8.6-4 [JDOFatalUserException] or
A8.6-5 [JDOFatalInternalException is thrown],
depending on whether the exception is due to the user
or the implementation.
The nested exception indicates the cause of the exception.
Field Summary | |
protected static java.lang.String |
invalidPropertiesFile
Used as the PMF name in negative tests. |
protected static java.lang.String |
jndiName
Used as the PMF name in positive JNDI tests. |
protected static java.lang.String |
validPropertiesFile
Used as the PMF name in positive tests. |
Fields inherited from class org.apache.jdo.tck.JDO_Test |
APPLICATION_IDENTITY, cleanupData, closePMFAfterEachTest, DATASTORE_IDENTITY, debug, DETACHED_CLEAN, DETACHED_DIRTY, HOLLOW, identitytype, ILLEGAL_STATE, logger, messages, NL, NUM_STATES, PERSISTENT_CLEAN, PERSISTENT_DELETED, PERSISTENT_DIRTY, PERSISTENT_NEW, PERSISTENT_NEW_DELETED, PERSISTENT_NONTRANSACTIONAL, PERSISTENT_NONTRANSACTIONAL_DIRTY, pm, pmf, PMFProperties, PMFPropertiesObject, states, testSucceeded, TRANSIENT, TRANSIENT_CLEAN, TRANSIENT_DIRTY |
Constructor Summary | |
GetPMFByStream()
|
Method Summary | |
protected void |
checkGetPMFWithInvalidProperties(java.lang.String assertionMessage)
This method creates a PMF calling method AbstractGetPMF#getPMF(name). |
protected void |
checkGetPMFWithValidProperties()
This method creates a PMF calling method AbstractGetPMF#getPMF(name). |
protected javax.jdo.PersistenceManagerFactory |
getPMF(java.lang.String name)
Returns pmf instance for the given name. |
static void |
main(java.lang.String[] args)
The main is called when the class
is directly executed from the command line. |
protected void |
makePersistent()
|
protected java.lang.String |
removePathPrefix(java.lang.String name)
Removing the path prefix from argument name . |
void |
testInvalidGetPMF()
|
void |
testValidGetPMF()
|
protected void |
verifyProperties(javax.jdo.PersistenceManagerFactory pmf,
java.util.Properties props)
Verify that the Properties are correctly set in the PMF. |
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, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static final java.lang.String validPropertiesFile
protected static java.lang.String invalidPropertiesFile
protected static final java.lang.String jndiName
Constructor Detail |
public GetPMFByStream()
Method Detail |
public static void main(java.lang.String[] args)
main
is called when the class
is directly executed from the command line.
args
- The arguments passed to the program.public void testInvalidGetPMF()
public void testValidGetPMF()
protected javax.jdo.PersistenceManagerFactory getPMF(java.lang.String name)
org.apache.jdo.tck.api.persistencemanagerfactory.AbstractGetPMF
name
as file name,
resource name etc.
name
- the name
protected java.lang.String removePathPrefix(java.lang.String name)
name
.
name
removed by the path prefix.protected void makePersistent()
protected void checkGetPMFWithInvalidProperties(java.lang.String assertionMessage)
assertionMessage
- the assertion message if the test fails.protected void checkGetPMFWithValidProperties()
protected void verifyProperties(javax.jdo.PersistenceManagerFactory pmf, java.util.Properties props)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |