kaori 4 лет назад
Родитель
Сommit
a7c2ae9451
1 измененных файлов с 4 добавлено и 1 удалено
  1. 4 1
      packages/app/test/integration/service/user-groups.test.ts

+ 4 - 1
packages/app/test/integration/service/user-groups.test.ts

@@ -128,9 +128,12 @@ describe('UserGroupService', () => {
 
     const forceUpdateParents = true;
 
-    await crowi.userGroupService.updateGroup(userGroup4._id, userGroup4.name, userGroup4.description, userGroup5._id, forceUpdateParents);
+    const updatedUserGroup = await crowi.userGroupService.updateGroup(
+      userGroup4._id, userGroup4.name, userGroup4.description, userGroup5._id, forceUpdateParents,
+    );
     const relatedGroup = await UserGroupRelation.findOne({ relatedGroup: userGroup5._id, relatedUser: userGroup4Relation.relatedUser });
 
+    expect(updatedUserGroup.parent).toStrictEqual(userGroup5._id);
     expect(relatedGroup).toBeTruthy();
   });