Test exclude members

This commit is contained in:
adrinr 2023-04-14 14:48:48 +01:00
parent 1301b23f02
commit ce2a610c00
1 changed files with 19 additions and 0 deletions

View File

@ -600,6 +600,25 @@ describe("scim", () => {
totalResults: 1,
})
})
it("can fetch groups excluding members", async () => {
const response = await getScimGroups({
params: { excludedAttributes: "members" },
})
expect(response).toEqual({
Resources: expect.arrayContaining(
groups.map(g => {
const { members, ...groupData } = g
return groupData
})
),
itemsPerPage: 25,
schemas: ["urn:ietf:params:scim:api:messages:2.0:ListResponse"],
startIndex: 1,
totalResults: groupCount,
})
})
})
})