logger.addAppender(appender);
try {
emfac = Persistence.createEntityManagerFactory("testAutoCreateSchemaFalse", dynamicOrgConfig);
em = emfac.createEntityManager();
ExistingCustomObject ent = new ExistingCustomObject();
ent.setExistingCustomField("some value");
EntityTransaction tx = em.getTransaction();
tx.begin();
em.persist(ent);
tx.commit();
ExistingCustomObject result = em.find(ExistingCustomObject.class, ent.getId());
Assert.assertEquals(result.getExistingCustomField(), "some value");
Assert.assertTrue(receivedTableLog.get(), "Did not receive log messages for missing tables");
Assert.assertTrue(receivedFieldLog.get(), "Did not receive log messages for missing fields");
} finally {
logger.setLevel(oldLevel);