### Question:
MongoDbTagRepository implements TagRepository { @Override public void delete(Tag item) { template.remove(query(where("_id").is(item.getId()))); }  @Override List<Tag> getAll(); @Override List<Tag> getLimitedList(int offset, int pageSize); @Override int getCountAll(); @Override Tag getByKeyword(String keyword); @Override Class<? extends Tag> getType(); @Override Tag get(String id); @Override Tag save(Tag item); @Override void delete(Tag item); void setWidgetTemplate(MongoTagOperations tagTemplate);  }### Answer:
@Test public void delete(){ String id ="id"; Tag tag = new TagImpl(id, "keyword"); tagTemplate.remove(Query.query(Criteria.where("_id").is(id))); expectLastCall(); replay(tagTemplate); repo.delete(tag); verify(tagTemplate); }