-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3e94fd9
commit 80b5c3d
Showing
4 changed files
with
56 additions
and
7 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
src/shared/models/entity/permission/permissionCollection.test.data.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/** | ||
* Passbolt ~ Open source password manager for teams | ||
* Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* | ||
* Licensed under GNU Affero General Public License version 3 of the or any later version. | ||
* For full copyright and license information, please see the LICENSE.txt | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @copyright Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* @license https://opensource.org/licenses/AGPL-3.0 AGPL License | ||
* @link https://www.passbolt.com Passbolt(tm) | ||
* @since 4.8.0 | ||
*/ | ||
|
||
|
||
import {defaultPermissionDto} from "./permissionEntity.test.data"; | ||
|
||
/** | ||
* Build dtos. | ||
* @param {number} [count=10] The number of dtos. | ||
* @returns {object} | ||
*/ | ||
export const defaultPermissionsDtos = (count = 10) => { | ||
const dtos = []; | ||
const acoForeignKey = crypto.randomUUID(); | ||
for (let i = 0; i < count; i++) { | ||
const groupDto = defaultPermissionDto({aco_foreign_key: acoForeignKey}); | ||
dtos.push(groupDto); | ||
} | ||
return dtos; | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters