### Question:
JpaTenantDao extends JpaAbstractSearchTextDao<TenantEntity, Tenant> implements TenantDao { @Override public List<Tenant> findTenantsByRegion(TenantId tenantId, String region, TextPageLink pageLink) { return DaoUtil.convertDataList(tenantRepository .findByRegionNextPage( region, Objects.toString(pageLink.getTextSearch(), ""), pageLink.getIdOffset() == null ? NULL_UUID_STR : UUIDConverter.fromTimeUUID(pageLink.getIdOffset()), new PageRequest(0, pageLink.getLimit()))); }  @Override List<Tenant> findTenantsByRegion(TenantId tenantId, String region, TextPageLink pageLink);  }### Answer:
@Test @DatabaseSetup("classpath:dbunit/empty_dataset.xml") public void testFindTenantsByRegion() { createTenants(); assertEquals(60, tenantDao.find(AbstractServiceTest.SYSTEM_TENANT_ID).size()); List<Tenant> tenants1 = tenantDao.findTenantsByRegion(AbstractServiceTest.SYSTEM_TENANT_ID, "REGION_1", new TextPageLink(20,"title")); assertEquals(20, tenants1.size()); List<Tenant> tenants2 = tenantDao.findTenantsByRegion(AbstractServiceTest.SYSTEM_TENANT_ID,"REGION_1", new TextPageLink(20,"title", tenants1.get(19).getId().getId(), null)); assertEquals(10, tenants2.size()); List<Tenant> tenants3 = tenantDao.findTenantsByRegion(AbstractServiceTest.SYSTEM_TENANT_ID,"REGION_1", new TextPageLink(20,"title", tenants2.get(9).getId().getId(), null)); assertEquals(0, tenants3.size()); }