Skip to content

Commit

Permalink
test(api): add a member role membership to 403 test
Browse files Browse the repository at this point in the history
  • Loading branch information
Libouk authored Mar 4, 2025
1 parent 671ef47 commit 413bc2f
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,13 @@ describe('Acceptance | Team | Application | Route | membership', function () {
it('should respond with a 403 if user does not have the role Admin in organization', async function () {
// given
const notOrganizationAdminUserId = databaseBuilder.factory.buildUser().id;
databaseBuilder.factory.buildMembership({
userId: notOrganizationAdminUserId,
organizationId,
organizationRole: Membership.roles.MEMBER,
});
await databaseBuilder.commit();

options.headers = generateAuthenticatedUserRequestHeaders({ userId: notOrganizationAdminUserId });

// when
Expand Down

0 comments on commit 413bc2f

Please sign in to comment.