}
public void testNullifyToOne() {
CayenneContext context = createClientContext();
ClientMtDeleteNullify object = context
.newObject(ClientMtDeleteNullify.class);
object.setName("object");
ClientMtDeleteRule related = context
.newObject(ClientMtDeleteRule.class);
object.setName("related");
object.setNullify(related);
context.commitChanges();
context.deleteObject(object);
assertFalse(related.getFromNullify().contains(object));
assertNull(object.getNullify());
// And be sure that the commit works afterwards, just for sanity
context.commitChanges();
}