public void testPersist(boolean useSameEm)
{
EntityManager em = emf.createEntityManager();
// Insert max value of BigInteger
StudentBigInteger studentMax = new StudentBigInteger();
studentMax.setAge((Short) getMaxValue(short.class));
studentMax.setId((BigInteger) getMaxValue(BigInteger.class));
studentMax.setName((String) getMaxValue(String.class));
em.persist(studentMax);
// Insert min value of BigInteger
StudentBigInteger studentMin = new StudentBigInteger();
studentMin.setAge((Short) getMinValue(short.class));
studentMin.setId((BigInteger) getMinValue(BigInteger.class));
studentMin.setName((String) getMinValue(String.class));
em.persist(studentMin);
// Insert random value of BigInteger
StudentBigInteger student = new StudentBigInteger();
student.setAge((Short) getRandomValue(short.class));
student.setId((BigInteger) getRandomValue(BigInteger.class));
student.setName((String) getRandomValue(String.class));
em.persist(student);
em.close();
}