From 69fa19a856260a1bd01d9063be6f7d7e13798ad5 Mon Sep 17 00:00:00 2001 From: wangzhs Date: Tue, 14 Mar 2023 21:45:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E5=8D=95=E6=B5=8B=E6=96=B9?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../user/AdminUserServiceImplTest.java | 31 ------------------- 1 file changed, 31 deletions(-) diff --git a/yudao-module-system/yudao-module-system-biz/src/test/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImplTest.java b/yudao-module-system/yudao-module-system-biz/src/test/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImplTest.java index 4ba5645f9..f35481535 100644 --- a/yudao-module-system/yudao-module-system-biz/src/test/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImplTest.java +++ b/yudao-module-system/yudao-module-system-biz/src/test/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImplTest.java @@ -774,37 +774,6 @@ public class AdminUserServiceImplTest extends BaseDbUnitTest { userDO.getNickname()); } - @Test - public void testSelectUserIncludeDept_success() { - - // 准备部门数据 - DeptDO dept = new DeptDO(); - dept.setName("测试"); - dept.setStatus(CommonStatusEnum.ENABLE.getStatus()); - deptMapper.insert(dept); - - // 准备用户参数 - UserCreateReqVO reqVO = randomPojo(UserCreateReqVO.class, o -> { - o.setSex(RandomUtil.randomEle(SexEnum.values()).getSex()); - o.setMobile(randomString()); - o.setPostIds(asSet(1L, 2L)); - o.setDeptId(dept.getId()); - }); - - // 调用 - Long userId = userService.createUser(reqVO); - - MPJLambdaWrapper wrapper = new MPJLambdaWrapper<>(AdminUserDO.class) - .selectAll(AdminUserDO.class) - .selectAssociation(DeptDO.class, AdminUserDO::getDept) - .leftJoin(DeptDO.class, DeptDO::getId, AdminUserDO::getDeptId) - .eq(AdminUserDO::getId, userId); - AdminUserDO user = userMapper.selectJoinOne(AdminUserDO.class, wrapper); - - System.out.println("=========>" + user); - } - - // ========== 随机对象 ========== @SafeVarargs