فهرست منبع

set test user name unique

kaori 3 سال پیش
والد
کامیت
30b6890cb4
1فایلهای تغییر یافته به همراه3 افزوده شده و 2 حذف شده
  1. 3 2
      packages/app/test/integration/service/user-groups.test.ts

+ 3 - 2
packages/app/test/integration/service/user-groups.test.ts

@@ -31,8 +31,9 @@ describe('UserGroupService', () => {
     UserGroupRelation = mongoose.model('UserGroupRelation');
     UserGroupRelation = mongoose.model('UserGroupRelation');
 
 
     await User.insertMany([
     await User.insertMany([
+      // ug -> User Group
       {
       {
-        _id: userId1, name: 'someone1', username: 'someone1', email: 'someone1@example.com',
+        _id: userId1, name: 'ug_test_user1', username: 'ug_test_user1', email: 'ug_test_user1@example.com',
       },
       },
     ]);
     ]);
 
 
@@ -269,7 +270,7 @@ describe('UserGroupService', () => {
 
 
     // remove user1 from the parent group
     // remove user1 from the parent group
     await crowi.userGroupService.removeUserByUsername(
     await crowi.userGroupService.removeUserByUsername(
-      userGroup11._id, 'someone1',
+      userGroup11._id, 'ug_test_user1',
     );
     );
 
 
     // Both groups have not user1
     // Both groups have not user1