Skip to content

Commit

Permalink
chore(test): reorg the sso connector api cleanup logic (#6053)
Browse files Browse the repository at this point in the history
reorg the sso connector api cleanup logic
  • Loading branch information
simeng-li committed Jun 20, 2024
1 parent 32270d1 commit 0f3dbbc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,12 @@ describe('manual data hook tests', () => {
});

afterEach(async () => {
await Promise.all([webHookApi.cleanUp(), userApi.cleanUp(), organizationApi.cleanUp()]);
await Promise.all([
webHookApi.cleanUp(),
userApi.cleanUp(),
organizationApi.cleanUp(),
ssoConnectorApi.cleanUp(),
]);
});

it('create roles with scopeIds should trigger Roles.Scopes.Updated event', async () => {
Expand Down Expand Up @@ -171,8 +176,6 @@ describe('manual data hook tests', () => {
});

await assertOrganizationMembershipUpdated(organization.id);

await ssoConnectorApi.cleanUp();
});
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ describe('organization just-in-time provisioning', () => {
const ssoConnectorApi = new SsoConnectorApi();

afterEach(async () => {
await organizationApi.cleanUp();
await Promise.all([organizationApi.cleanUp(), ssoConnectorApi.cleanUp()]);
});

beforeAll(async () => {
Expand Down Expand Up @@ -120,6 +120,5 @@ describe('organization just-in-time provisioning', () => {
);

await deleteUser(userId);
await ssoConnectorApi.cleanUp();
});
});

0 comments on commit 0f3dbbc

Please sign in to comment.