if (!useSameEm)
{
em.close();
em = emf.createEntityManager();
}
StudentShortPrimitive newStudent = em.find(StudentShortPrimitive.class, getRandomValue(Short.class));
Assert.assertNotNull(newStudent);
Assert.assertEquals(getRandomValue(short.class), newStudent.getAge());
Assert.assertEquals("Vivek", newStudent.getName());
em.close();
}