public void testOptRetainStateTransitions5()
throws Exception {
OpenJPAEntityManager pm = getPM(true, true);
startTx(pm);
ModRuntimeTest2 b = pm.find(ModRuntimeTest2.class, _id);
ModRuntimeTest1 parent = b.getSelfOneOne();
assertNotNull("parent is null", parent);
pm.remove(b);
endTx(pm);
// parent should be valid
assertEquals("PARENT", parent.getStringField());
// 'b' should not be cleared JPA 2.0 "3.2.3 Removal"
assertNotNull(b.getStringField());
assertNotEquals(0, b.getIntField());
assertNotNull(b.getSelfOneOne());
}