### Question:
TypeEditor { public T remove() { target.editor().remove(key); return target; } protected  TypeEditor(T target, SharedPreferences sharedPreferences, String key); T put(ValueType value); @TargetApi(Build.VERSION_CODES.GINGERBREAD) void save(ValueType value); ValueType getOr(ValueType def); T remove();  }### Answer:
@Test public void testRemoveApply() { mTypeEditor.remove(); verify(mMockEditor, never()).apply(); mTypeEditor.remove().apply(); verify(mMockEditor).apply(); }
@Test public void testRemoveCommit() { mTypeEditor.remove(); verify(mMockEditor, never()).commit(); mTypeEditor.remove().commit(); verify(mMockEditor).commit(); }