Search in sources :

Example 1 with PageResult

use of cn.iocoder.yudao.framework.common.pojo.PageResult in project ruoyi-vue-pro by YunaiV.

the class FileServiceTest method testGetFilePage.

@Test
public void testGetFilePage() {
    // mock 数据
    FileDO dbFile = randomPojo(FileDO.class, o -> {
        // 等会查询到
        o.setId("yunai");
        o.setType("jpg");
        o.setCreateTime(buildTime(2021, 1, 15));
    });
    fileMapper.insert(dbFile);
    // 测试 id 不匹配
    fileMapper.insert(ObjectUtils.cloneIgnoreId(dbFile, o -> o.setId("tudou")));
    // 测试 type 不匹配
    fileMapper.insert(ObjectUtils.cloneIgnoreId(dbFile, o -> {
        o.setId("yunai02");
        o.setType("png");
    }));
    // 测试 createTime 不匹配
    fileMapper.insert(ObjectUtils.cloneIgnoreId(dbFile, o -> {
        o.setId("yunai03");
        o.setCreateTime(buildTime(2020, 1, 15));
    }));
    // 准备参数
    FilePageReqVO reqVO = new FilePageReqVO();
    reqVO.setId("yunai");
    reqVO.setType("jp");
    reqVO.setBeginCreateTime(buildTime(2021, 1, 10));
    reqVO.setEndCreateTime(buildTime(2021, 1, 20));
    // 调用
    PageResult<FileDO> pageResult = fileService.getFilePage(reqVO);
    // 断言
    assertEquals(1, pageResult.getTotal());
    assertEquals(1, pageResult.getList().size());
    AssertUtils.assertPojoEquals(dbFile, pageResult.getList().get(0), "content");
}
Also used : FileProperties(cn.iocoder.yudao.module.infra.framework.file.config.FileProperties) FileDO(cn.iocoder.yudao.module.infra.dal.dataobject.file.FileDO) ResourceUtil(cn.hutool.core.io.resource.ResourceUtil) Resource(javax.annotation.Resource) Import(org.springframework.context.annotation.Import) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) RandomUtils.randomPojo(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo) PageResult(cn.iocoder.yudao.framework.common.pojo.PageResult) FileMapper(cn.iocoder.yudao.module.infra.dal.mysql.file.FileMapper) Test(org.junit.jupiter.api.Test) DateUtils.buildTime(cn.iocoder.yudao.framework.common.util.date.DateUtils.buildTime) RandomUtils.randomString(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomString) AssertUtils.assertServiceException(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertServiceException) ErrorCodeConstants(cn.iocoder.yudao.module.infra.enums.ErrorCodeConstants) Assertions(org.junit.jupiter.api.Assertions) ObjectUtils(cn.iocoder.yudao.framework.common.util.object.ObjectUtils) AssertUtils(cn.iocoder.yudao.framework.test.core.util.AssertUtils) FilePageReqVO(cn.iocoder.yudao.module.infra.controller.admin.file.vo.FilePageReqVO) MockBean(org.springframework.boot.test.mock.mockito.MockBean) FilePageReqVO(cn.iocoder.yudao.module.infra.controller.admin.file.vo.FilePageReqVO) FileDO(cn.iocoder.yudao.module.infra.dal.dataobject.file.FileDO) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) Test(org.junit.jupiter.api.Test)

Example 2 with PageResult

use of cn.iocoder.yudao.framework.common.pojo.PageResult in project ruoyi-vue-pro by YunaiV.

the class JobLogServiceTest method testGetJobPage_success.

@Test
public void testGetJobPage_success() {
    // mock 数据
    JobLogDO dbJobLog = randomPojo(JobLogDO.class, o -> {
        o.setExecuteIndex(1);
        o.setHandlerName("handlerName 单元测试");
        o.setStatus(JobLogStatusEnum.SUCCESS.getStatus());
        o.setBeginTime(buildTime(2021, 1, 8));
        o.setEndTime(buildTime(2021, 1, 8));
    });
    jobLogMapper.insert(dbJobLog);
    // 测试 jobId 不匹配
    jobLogMapper.insert(ObjectUtils.cloneIgnoreId(dbJobLog, o -> o.setJobId(randomLongId())));
    // 测试 handlerName 不匹配
    jobLogMapper.insert(ObjectUtils.cloneIgnoreId(dbJobLog, o -> o.setHandlerName(randomString())));
    // 测试 beginTime 不匹配
    jobLogMapper.insert(ObjectUtils.cloneIgnoreId(dbJobLog, o -> o.setBeginTime(buildTime(2021, 1, 7))));
    // 测试 endTime 不匹配
    jobLogMapper.insert(ObjectUtils.cloneIgnoreId(dbJobLog, o -> o.setEndTime(buildTime(2021, 1, 9))));
    // 测试 status 不匹配
    jobLogMapper.insert(ObjectUtils.cloneIgnoreId(dbJobLog, o -> o.setStatus(JobLogStatusEnum.FAILURE.getStatus())));
    // 准备参数
    JobLogPageReqVO reqVo = new JobLogPageReqVO();
    reqVo.setJobId(dbJobLog.getJobId());
    reqVo.setHandlerName("单元");
    reqVo.setBeginTime(dbJobLog.getBeginTime());
    reqVo.setEndTime(dbJobLog.getEndTime());
    reqVo.setStatus(JobLogStatusEnum.SUCCESS.getStatus());
    // 调用
    PageResult<JobLogDO> pageResult = jobLogService.getJobLogPage(reqVo);
    // 断言
    assertEquals(1, pageResult.getTotal());
    assertEquals(1, pageResult.getList().size());
    assertPojoEquals(dbJobLog, pageResult.getList().get(0));
}
Also used : Assertions.assertNotNull(org.junit.jupiter.api.Assertions.assertNotNull) JobLogMapper(cn.iocoder.yudao.module.infra.dal.mysql.job.JobLogMapper) JobLogStatusEnum(cn.iocoder.yudao.module.infra.enums.job.JobLogStatusEnum) Resource(javax.annotation.Resource) AssertUtils.assertPojoEquals(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals) Import(org.springframework.context.annotation.Import) RandomUtils.randomPojo(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) PageResult(cn.iocoder.yudao.framework.common.pojo.PageResult) ArrayList(java.util.ArrayList) Test(org.junit.jupiter.api.Test) DateUtils.buildTime(cn.iocoder.yudao.framework.common.util.date.DateUtils.buildTime) RandomUtils.randomString(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomString) List(java.util.List) RandomUtil.randomEle(cn.hutool.core.util.RandomUtil.randomEle) JobLogExportReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogExportReqVO) Assertions.assertEquals(org.junit.jupiter.api.Assertions.assertEquals) ObjectUtils(cn.iocoder.yudao.framework.common.util.object.ObjectUtils) JobLogDO(cn.iocoder.yudao.module.infra.dal.dataobject.job.JobLogDO) RandomUtils.randomLongId(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomLongId) JobLogPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogPageReqVO) JobLogPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogPageReqVO) JobLogDO(cn.iocoder.yudao.module.infra.dal.dataobject.job.JobLogDO) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) Test(org.junit.jupiter.api.Test)

Example 3 with PageResult

use of cn.iocoder.yudao.framework.common.pojo.PageResult in project ruoyi-vue-pro by YunaiV.

the class JobServiceTest method testGetJobPage_success.

@Test
public void testGetJobPage_success() {
    // mock 数据
    JobDO dbJob = randomPojo(JobDO.class, o -> {
        o.setName("定时任务测试");
        o.setHandlerName("handlerName 单元测试");
        o.setStatus(JobStatusEnum.INIT.getStatus());
    });
    jobMapper.insert(dbJob);
    // 测试 name 不匹配
    jobMapper.insert(ObjectUtils.cloneIgnoreId(dbJob, o -> o.setName("土豆")));
    // 测试 status 不匹配
    jobMapper.insert(ObjectUtils.cloneIgnoreId(dbJob, o -> o.setStatus(JobStatusEnum.NORMAL.getStatus())));
    // 测试 handlerName 不匹配
    jobMapper.insert(ObjectUtils.cloneIgnoreId(dbJob, o -> o.setHandlerName(randomString())));
    // 准备参数
    JobPageReqVO reqVo = new JobPageReqVO();
    reqVo.setName("定时");
    reqVo.setStatus(JobStatusEnum.INIT.getStatus());
    reqVo.setHandlerName("单元");
    // 调用
    PageResult<JobDO> pageResult = jobService.getJobPage(reqVo);
    // 断言
    assertEquals(1, pageResult.getTotal());
    assertEquals(1, pageResult.getList().size());
    assertPojoEquals(dbJob, pageResult.getList().get(0));
}
Also used : Assertions.assertNotNull(org.junit.jupiter.api.Assertions.assertNotNull) ArgumentMatchers.eq(org.mockito.ArgumentMatchers.eq) Assertions.assertNull(org.junit.jupiter.api.Assertions.assertNull) PageResult(cn.iocoder.yudao.framework.common.pojo.PageResult) ArrayList(java.util.ArrayList) JobUpdateReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobUpdateReqVO) RandomUtils.randomString(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomString) SchedulerException(org.quartz.SchedulerException) JobMapper(cn.iocoder.yudao.module.infra.dal.mysql.job.JobMapper) ErrorCodeConstants(cn.iocoder.yudao.module.infra.enums.ErrorCodeConstants) Assertions.assertEquals(org.junit.jupiter.api.Assertions.assertEquals) JobDO(cn.iocoder.yudao.module.infra.dal.dataobject.job.JobDO) MockBean(org.springframework.boot.test.mock.mockito.MockBean) JobConvert(cn.iocoder.yudao.module.infra.convert.job.JobConvert) JobCreateReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobCreateReqVO) Resource(javax.annotation.Resource) AssertUtils.assertPojoEquals(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals) Import(org.springframework.context.annotation.Import) SchedulerManager(cn.iocoder.yudao.framework.quartz.core.scheduler.SchedulerManager) Mockito.times(org.mockito.Mockito.times) JobPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobPageReqVO) RandomUtils.randomPojo(cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) JobExportReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobExportReqVO) Mockito.verify(org.mockito.Mockito.verify) Test(org.junit.jupiter.api.Test) List(java.util.List) JobStatusEnum(cn.iocoder.yudao.module.infra.enums.job.JobStatusEnum) AssertUtils.assertServiceException(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertServiceException) RandomUtil.randomEle(cn.hutool.core.util.RandomUtil.randomEle) ObjectUtils(cn.iocoder.yudao.framework.common.util.object.ObjectUtils) JobPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.JobPageReqVO) JobDO(cn.iocoder.yudao.module.infra.dal.dataobject.job.JobDO) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) Test(org.junit.jupiter.api.Test)

Example 4 with PageResult

use of cn.iocoder.yudao.framework.common.pojo.PageResult in project ruoyi-vue-pro by YunaiV.

the class ApiAccessLogServiceImplTest method testGetApiAccessLogPage.

@Test
public void testGetApiAccessLogPage() {
    // 构造测试数据
    long userId = 2233L;
    int userType = UserTypeEnum.ADMIN.getValue();
    String applicationName = "yudao-test";
    String requestUrl = "foo";
    Date beginTime = buildTime(2021, 3, 13);
    int duration = 1000;
    int resultCode = GlobalErrorCodeConstants.SUCCESS.getCode();
    ApiAccessLogDO infApiAccessLogDO = RandomUtils.randomPojo(ApiAccessLogDO.class, dto -> {
        dto.setUserId(userId);
        dto.setUserType(userType);
        dto.setApplicationName(applicationName);
        dto.setRequestUrl(requestUrl);
        dto.setBeginTime(beginTime);
        dto.setDuration(duration);
        dto.setResultCode(resultCode);
    });
    apiAccessLogMapper.insert(infApiAccessLogDO);
    // 下面几个都是不匹配的数据
    // userId 不同的
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setUserId(3344L)));
    // userType
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setUserType(UserTypeEnum.MEMBER.getValue())));
    // applicationName 不同的
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setApplicationName("test")));
    // requestUrl 不同的
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setRequestUrl("bar")));
    // 构造一个早期时间 2021-02-06 00:00:00
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setBeginTime(buildTime(2021, 2, 6))));
    // duration 不同的
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setDuration(100)));
    // resultCode 不同的
    apiAccessLogMapper.insert(ObjectUtils.cloneIgnoreId(infApiAccessLogDO, logDO -> logDO.setResultCode(2)));
    // 构造调用参数
    ApiAccessLogPageReqVO reqVO = new ApiAccessLogPageReqVO();
    reqVO.setUserId(userId);
    reqVO.setUserType(userType);
    reqVO.setApplicationName(applicationName);
    reqVO.setRequestUrl(requestUrl);
    reqVO.setBeginBeginTime(buildTime(2021, 3, 12));
    reqVO.setEndBeginTime(buildTime(2021, 3, 14));
    reqVO.setDuration(duration);
    reqVO.setResultCode(resultCode);
    // 调用service方法
    PageResult<ApiAccessLogDO> pageResult = apiAccessLogService.getApiAccessLogPage(reqVO);
    // 断言,只查到了一条符合条件的
    assertEquals(1, pageResult.getTotal());
    assertEquals(1, pageResult.getList().size());
    assertPojoEquals(infApiAccessLogDO, pageResult.getList().get(0));
}
Also used : Assertions.assertNotNull(org.junit.jupiter.api.Assertions.assertNotNull) ApiAccessLogPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogPageReqVO) Date(java.util.Date) UserTypeEnum(cn.iocoder.yudao.framework.common.enums.UserTypeEnum) ApiAccessLogDO(cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiAccessLogDO) Resource(javax.annotation.Resource) ApiAccessLogExportReqVO(cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogExportReqVO) Import(org.springframework.context.annotation.Import) AssertUtils.assertPojoEquals(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals) ApiAccessLogCreateReqDTO(cn.iocoder.yudao.framework.apilog.core.service.dto.ApiAccessLogCreateReqDTO) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) PageResult(cn.iocoder.yudao.framework.common.pojo.PageResult) Test(org.junit.jupiter.api.Test) ApiAccessLogMapper(cn.iocoder.yudao.module.infra.dal.mysql.logger.ApiAccessLogMapper) DateUtils.buildTime(cn.iocoder.yudao.framework.common.util.date.DateUtils.buildTime) List(java.util.List) RandomUtils(cn.iocoder.yudao.framework.test.core.util.RandomUtils) RandomUtil(cn.hutool.core.util.RandomUtil) GlobalErrorCodeConstants(cn.iocoder.yudao.framework.common.exception.enums.GlobalErrorCodeConstants) ObjectUtils(cn.iocoder.yudao.framework.common.util.object.ObjectUtils) Assertions.assertEquals(org.junit.jupiter.api.Assertions.assertEquals) ApiAccessLogDO(cn.iocoder.yudao.module.infra.dal.dataobject.logger.ApiAccessLogDO) ApiAccessLogPageReqVO(cn.iocoder.yudao.module.infra.controller.admin.logger.vo.apiaccesslog.ApiAccessLogPageReqVO) Date(java.util.Date) BaseDbUnitTest(cn.iocoder.yudao.module.infra.test.BaseDbUnitTest) Test(org.junit.jupiter.api.Test)

Example 5 with PageResult

use of cn.iocoder.yudao.framework.common.pojo.PageResult in project ruoyi-vue-pro by YunaiV.

the class UserSessionServiceImplTest method testGetUserSessionPage_success.

@Test
public void testGetUserSessionPage_success() {
    // mock 数据
    AdminUserDO dbUser = randomPojo(AdminUserDO.class, o -> {
        o.setSex(randomEle(SexEnum.values()).getSex());
        o.setStatus(CommonStatusEnum.ENABLE.getStatus());
    });
    when(userService.getUsersByUsername(eq(dbUser.getUsername()))).thenReturn(singletonList(dbUser));
    // 插入可被查询到的数据
    String userIp = randomString();
    UserSessionDO dbSession = randomPojo(UserSessionDO.class, o -> {
        o.setUserId(dbUser.getId());
        o.setUserType(randomEle(UserTypeEnum.values()).getValue());
        o.setUserIp(userIp);
    });
    userSessionMapper.insert(dbSession);
    // 测试 username 不匹配
    userSessionMapper.insert(ObjectUtils.cloneIgnoreId(dbSession, o -> {
        o.setId(randomString());
        o.setUserId(123456L);
    }));
    // 测试 userIp 不匹配
    userSessionMapper.insert(ObjectUtils.cloneIgnoreId(dbSession, o -> {
        o.setId(randomString());
        o.setUserIp("testUserIp");
    }));
    // 准备参数
    UserSessionPageReqVO reqVO = new UserSessionPageReqVO();
    reqVO.setUsername(dbUser.getUsername());
    reqVO.setUserIp(userIp);
    // 调用
    PageResult<UserSessionDO> pageResult = userSessionService.getUserSessionPage(reqVO);
    // 断言
    assertEquals(1, pageResult.getTotal());
    assertEquals(1, pageResult.getList().size());
    assertPojoEquals(dbSession, pageResult.getList().get(0));
}
Also used : DateUtil(cn.hutool.core.date.DateUtil) DateUtils.addTime(cn.iocoder.yudao.framework.common.util.date.DateUtils.addTime) Date(java.util.Date) ArgumentMatchers.eq(org.mockito.ArgumentMatchers.eq) Assertions.assertNull(org.junit.jupiter.api.Assertions.assertNull) SecurityProperties(cn.iocoder.yudao.framework.security.config.SecurityProperties) BaseDbAndRedisUnitTest(cn.iocoder.yudao.module.system.test.BaseDbAndRedisUnitTest) PageResult(cn.iocoder.yudao.framework.common.pojo.PageResult) Collections.singletonList(java.util.Collections.singletonList) UserSessionPageReqVO(cn.iocoder.yudao.module.system.controller.admin.auth.vo.session.UserSessionPageReqVO) LoginLogService(cn.iocoder.yudao.module.system.service.logger.LoginLogService) SexEnum(cn.iocoder.yudao.module.system.enums.common.SexEnum) Duration(java.time.Duration) CommonStatusEnum(cn.iocoder.yudao.framework.common.enums.CommonStatusEnum) LoginUser(cn.iocoder.yudao.framework.security.core.LoginUser) MockBean(org.springframework.boot.test.mock.mockito.MockBean) AdminUserService(cn.iocoder.yudao.module.system.service.user.AdminUserService) UserTypeEnum(cn.iocoder.yudao.framework.common.enums.UserTypeEnum) Resource(javax.annotation.Resource) LoginUserRedisDAO(cn.iocoder.yudao.module.system.dal.redis.auth.LoginUserRedisDAO) Import(org.springframework.context.annotation.Import) AssertUtils.assertPojoEquals(cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals) Mockito.when(org.mockito.Mockito.when) Collectors(java.util.stream.Collectors) Test(org.junit.jupiter.api.Test) List(java.util.List) Stream(java.util.stream.Stream) RandomUtils(cn.iocoder.yudao.framework.test.core.util.RandomUtils) UserSessionMapper(cn.iocoder.yudao.module.system.dal.mysql.auth.UserSessionMapper) RandomUtil.randomEle(cn.hutool.core.util.RandomUtil.randomEle) AdminUserDO(cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO) Assertions(org.junit.jupiter.api.Assertions) UserSessionDO(cn.iocoder.yudao.module.system.dal.dataobject.auth.UserSessionDO) ObjectUtils(cn.iocoder.yudao.framework.common.util.object.ObjectUtils) UserSessionPageReqVO(cn.iocoder.yudao.module.system.controller.admin.auth.vo.session.UserSessionPageReqVO) AdminUserDO(cn.iocoder.yudao.module.system.dal.dataobject.user.AdminUserDO) UserSessionDO(cn.iocoder.yudao.module.system.dal.dataobject.auth.UserSessionDO) BaseDbAndRedisUnitTest(cn.iocoder.yudao.module.system.test.BaseDbAndRedisUnitTest) Test(org.junit.jupiter.api.Test)

Aggregations

PageResult (cn.iocoder.yudao.framework.common.pojo.PageResult)31 Resource (javax.annotation.Resource)29 Test (org.junit.jupiter.api.Test)27 Import (org.springframework.context.annotation.Import)27 AssertUtils.assertPojoEquals (cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertPojoEquals)24 List (java.util.List)22 Assertions (org.junit.jupiter.api.Assertions)18 DateUtils.buildTime (cn.iocoder.yudao.framework.common.util.date.DateUtils.buildTime)17 ObjectUtils (cn.iocoder.yudao.framework.common.util.object.ObjectUtils)17 AssertUtils.assertServiceException (cn.iocoder.yudao.framework.test.core.util.AssertUtils.assertServiceException)17 CommonStatusEnum (cn.iocoder.yudao.framework.common.enums.CommonStatusEnum)16 MockBean (org.springframework.boot.test.mock.mockito.MockBean)16 RandomUtils (cn.iocoder.yudao.framework.test.core.util.RandomUtils)14 RandomUtil.randomEle (cn.hutool.core.util.RandomUtil.randomEle)13 RandomUtils.randomPojo (cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomPojo)13 BaseDbUnitTest (cn.iocoder.yudao.module.system.test.BaseDbUnitTest)12 ObjectUtils.cloneIgnoreId (cn.iocoder.yudao.framework.common.util.object.ObjectUtils.cloneIgnoreId)10 RandomUtils.randomLongId (cn.iocoder.yudao.framework.test.core.util.RandomUtils.randomLongId)10 Assertions.assertEquals (org.junit.jupiter.api.Assertions.assertEquals)10 RandomUtil (cn.hutool.core.util.RandomUtil)8