### Question:
ResourceImpl implements Resource, Serializable { public void accept(ResourceVisitor visitor) { visitor.visit(this); } protected  ResourceImpl(); protected  ResourceImpl(ResourceImpl another); @Override Serializable getIdentifier(); @Override String getType(); String getName(); void setName(String name); String getLabel(); void setLabel(String label); String getDescription(); void setDescription(String description); String getURIString(); void setURIString(String uri); String getPath(); String getProtocol(); String getURI(); String getParentURI(); String getParentPath(); String getParentFolder(); void setParentFolder(Folder folder); void setParentFolder(String folderURI); List getAttributes(); void setAttributes(List attrs); int getVersion(); void setVersion(int version); String getResourceType(); boolean isSameType(Resource resource); Date getCreationDate(); void setCreationDate(Date creationDate); Date getUpdateDate(); void setUpdateDate(Date updateDate); boolean isNew(); void accept(ResourceVisitor visitor);  }### Answer:
@Test public void accept_success() { ResourceImpl resource = new ResourceImpl() { @Override protected Class getImplementingItf() { return null; } }; resource.accept(visitor); verify(visitor, times(1)).visit(resource); }