final static Logger log = LoggerFactory.getLogger(JPAConverterTest.class);
- EntityManager em =
- Persistence.createEntityManagerFactory("test").createEntityManager();
+ EntityManager em;
ZonedDateTime zdt = ZonedDateTime.now();
OffsetDateTime odt = OffsetDateTime.now();
@Test
+ public void testOffsetDateTimeAnnotated()
+ {
+ em = Persistence.createEntityManagerFactory("annotated").createEntityManager();
+ testOffsetDateTime();
+ }
+
public void testOffsetDateTime()
{
EierlegendeWollmilchSau ews;
}
@Test
+ public void testZonedDateTimeAnnotated()
+ {
+ em = Persistence.createEntityManagerFactory("annotated").createEntityManager();
+ testZonedDateTime();
+ }
+
public void testZonedDateTime()
{
EierlegendeWollmilchSau ews;
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
version="1.0">
- <persistence-unit name="test">
+ <persistence-unit name="annotated">
<class>de.juplo.jpa.converters.OffsetDateTime</class>
<class>de.juplo.jpa.converters.ZonedDateTime</class>
<properties>