### Question:
OperateLogServiceImpl extends DefaultCrudService<OperateLog> implements OperateLogService { public List<OperateLog> find(String ptype, String pid) { return this.worklogDao.find(ptype, pid); }  @Autowired void setWorklogDao(OperateLogDao worklogDao); @Autowired void setIdGeneratorService(IdGeneratorService idGeneratorService); List<OperateLog> find(String ptype, String pid); OperateLog saveWorkLog(String ptype, String pid, String subject,
                                String content, String operate); OperateLog saveWorkLog(String ptype, String pid, String subject,
                                String content, String operate, int way); OperateLog saveAuditLog(String ptype, String pid,
                                 Set<AuditItem> auditItems, String subject, String content,
                                 String operate);  }### Answer:
@Test public void testFindWithParent() { OperateLog worklog = this.createInstance(getDefaultConfig()); worklog.setPtype("ptype"); worklog.setPid(UUID.randomUUID().toString()); Assert.assertNull(worklog.getId()); worklogService.save(worklog); Assert.assertNotNull(worklog.getId()); List<OperateLog> worklogs = this.worklogService.find( worklog.getPtype(), worklog.getPid()); Assert.assertNotNull(worklogs); Assert.assertEquals(1, worklogs.size()); Assert.assertEquals(worklog.getId(), worklogs.get(0).getId()); }