MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
com.mysql.clusterj.jpatest.PersistenceTestCase Class Reference
Inheritance diagram for com.mysql.clusterj.jpatest.PersistenceTestCase:
Collaboration diagram for com.mysql.clusterj.jpatest.PersistenceTestCase:

Public Member Functions

void run (TestResult testResult)
void tearDown () throws Exception

Protected Member Functions

EntityManagerFactory createEMF (Object...props)
String getPersistenceUnitName ()
EntityManagerFactory createNamedEMF (String pu, Object...props)
boolean closeEMF (EntityManagerFactory emf)
void initializeErrorMessages ()
void error (String message)
void errorIfNotEqual (String message, Object expected, Object actual)
void errorIfNull (String message, Object actual)
void failOnError ()

Protected Attributes

TestResult testResult
Map map

Detailed Description

Base class for all ClusterJPA test cases.

Definition at line 34 of file PersistenceTestCase.java.

Member Function Documentation

boolean com.mysql.clusterj.jpatest.PersistenceTestCase.closeEMF ( EntityManagerFactory  emf)
inlineprotected

Close the EMF.

Definition at line 123 of file PersistenceTestCase.java.

Here is the caller graph for this function:

EntityManagerFactory com.mysql.clusterj.jpatest.PersistenceTestCase.createEMF ( Object...  props)
inlineprotected

Create an entity manager factory from properties.

Parameters
propsconfiguration values in the form key, value, key, value...

Definition at line 57 of file PersistenceTestCase.java.

Here is the call graph for this function:

Here is the caller graph for this function:

EntityManagerFactory com.mysql.clusterj.jpatest.PersistenceTestCase.createNamedEMF ( String  pu,
Object...  props 
)
inlineprotected

Create an entity manager factory for persistence unit pu.

Parameters
propsconfiguration values in the form key, value, key, value...

Definition at line 87 of file PersistenceTestCase.java.

Here is the caller graph for this function:

String com.mysql.clusterj.jpatest.PersistenceTestCase.getPersistenceUnitName ( )
inlineprotected

The name of the persistence unit that this test class should use by default. This defaults to "ndb".

Reimplemented in com.mysql.clusterj.jpatest.EmbeddedTest, com.mysql.clusterj.openjpatest.LongLongStringPKOneManyTest, and com.mysql.clusterj.openjpatest.LongIntStringPKOneOneTest.

Definition at line 72 of file PersistenceTestCase.java.

Here is the caller graph for this function:

Member Data Documentation

Map com.mysql.clusterj.jpatest.PersistenceTestCase.map
protected

The properties used to create the entity manager factory

Definition at line 51 of file PersistenceTestCase.java.

TestResult com.mysql.clusterj.jpatest.PersistenceTestCase.testResult
protected

The TestResult instance for the current test run.

Definition at line 40 of file PersistenceTestCase.java.


The documentation for this class was generated from the following file: