TestContext ctx = TestContext.get();
emfac4 = Persistence.createEntityManagerFactory(ctx.getPersistenceUnitName() + "4");
em4 = emfac4.createEntityManager();
JarEntity entity = new JarEntity();
entity.setName("jar entity");
EntityTransaction tx = em4.getTransaction();
try {
tx.begin();
em4.persist(entity);
Assert.assertTrue(em4.contains(entity), "The entity was not stored to the database.");