### Question:
TagsService { public Page<TagDto> findTagsByCondition(TagDto tagDto, Pageable pageable) { Specification<Tag> condition = (root, query, builder) -> { List<javax.persistence.criteria.Predicate> predicates = new ArrayList<>(); if (StringUtils.isNotEmpty(tagDto.getName())) { predicates.add(builder.like(root.get("name"), "%" + tagDto.getName() + "%")); } if (tagDto.getState() != null) { predicates.add(builder.equal(root.get("state"), tagDto.getState())); } return query.where(predicates.toArray(new Predicate[0])).getRestriction(); }; Page<TagDto> tagsQueryResults = tagDao.findAll(condition, pageable) .map(tagMapper::toDto); List<ArticleTag> articleTags = articleTagDao.findAllByTagIdIn(tagsQueryResults.getContent().stream().map(TagDto::getId).collect(Collectors.toList())); Map<String, List<ArticleTag>> tagIds = articleTags.stream() .collect(Collectors.groupingBy(ArticleTag::getTagId)); tagsQueryResults.forEach(tag -> { if (tagIds.get(tag.getId()) != null) { tag.setTagsCount(tagIds.get(tag.getId()).size()); } }); return tagsQueryResults; } TagsService(TagDao tagDao, ArticleTagDao articleTagDao, TagMapper tagMapper); Page<TagDto> findTagsByCondition(TagDto tagDto, Pageable pageable); TagDto findTagsById(String id); void saveOrUpdate(TagDto tagDto); void deleteBatch(List<String> tagIds);  }### Answer:
@Test void testFindTagsByCondition() { Page<TagDto> result = tagsService.findTagsByCondition(new TagDto(), null); Assertions.assertEquals(null, result); }