common.setName("xxxx");
common.setDiff("diff");
common.setNum(56);
mgr.put(common);
InheritanceToOneSpecific ent1 = new InheritanceToOneSpecific();
ent1.setInheritance(common);
mgr.put(ent1);
mgr.flush();
InheritanceToOneSpecific result1 = mgr.find(InheritanceToOneSpecific.class, ent1.getId());
Assert.assertTrue(result1.getInheritance() instanceof InheritanceSub1);
Assert.assertEquals(common.getNum(), result1.getInheritance().getNum());
InheritanceSub1 subResult1 = (InheritanceSub1) result1.getInheritance();
Assert.assertEquals(common.getDiff(), subResult1.getDiff());
Assert.assertEquals(common.getName(), subResult1.getName());
}