### Question:
ParseRelation implements Parcelable { public void remove(T object) { synchronized (mutex) { ParseRelationOperation<T> operation = new ParseRelationOperation<>(null, Collections.singleton(object)); targetClass = operation.getTargetClass(); getParent().performOperation(key, operation); knownObjects.remove(object); } } ParseRelation(ParseObject parent, String key);   ParseRelation(String targetClass);   ParseRelation(JSONObject jsonObject, ParseDecoder decoder);   ParseRelation(Parcel source, ParseParcelDecoder decoder); void add(T object); void remove(T object); ParseQuery<T> getQuery(); @Override int describeContents(); @Override void writeToParcel(Parcel dest, int flags); final static Creator<ParseRelation> CREATOR; }### Answer:
@Test public void testRemove() throws Exception { ParseObject parent = new ParseObject("Parent"); ParseRelation relation = new ParseRelation(parent, "key"); ParseObject object = new ParseObject("Test"); relation.add(object); relation.remove(object); assertEquals("Test", relation.getTargetClass()); assertFalse(relation.hasKnownObject(object)); ParseRelation relationInParent = parent.getRelation("key"); assertEquals("Test", relationInParent.getTargetClass()); assertFalse(relation.hasKnownObject(object)); }
@Test public void testRemove() { ParseObject parent = new ParseObject("Parent"); ParseRelation relation = new ParseRelation(parent, "key"); ParseObject object = new ParseObject("Test"); relation.add(object); relation.remove(object); assertEquals("Test", relation.getTargetClass()); assertFalse(relation.hasKnownObject(object)); ParseRelation relationInParent = parent.getRelation("key"); assertEquals("Test", relationInParent.getTargetClass()); assertFalse(relation.hasKnownObject(object)); }