1
0
Fork 0
mirror of synced 2024-07-06 23:10:57 +12:00

Add new test for conflicting user email

This commit is contained in:
adrinr 2023-04-05 10:56:55 +01:00
parent 0acb821b70
commit 57a3ff96ea

View file

@ -318,6 +318,15 @@ describe("scim", () => {
await postScimUser({ body }, { expect: 500 }) await postScimUser({ body }, { expect: 500 })
}) })
}) })
it("creating an existing user name returns a conflict", async () => {
const body = structures.scim.createUserRequest()
await postScimUser({ body })
const res = await postScimUser({ body }, { expect: 409 })
expect((res as any).message).toBe("Email already in use")
})
}) })
describe("GET /api/global/scim/v2/users/:id", () => { describe("GET /api/global/scim/v2/users/:id", () => {