mirror of
https://github.com/open-reception/appointment-booking-software.git
synced 2026-09-27 03:14:48 +02:00
Fix tests
This commit is contained in:
@@ -160,16 +160,6 @@ describe("Send Email API", () => {
|
||||
await expect(POST(createEvent())).rejects.toBeInstanceOf(AuthorizationError);
|
||||
});
|
||||
|
||||
it("rejects roles other than staff and tenant admin", async () => {
|
||||
await expect(
|
||||
POST(
|
||||
createEvent(validBody, {
|
||||
locals: { user: { id: "user-123", tenantId: mockTenantId, role: "USER" } } as any,
|
||||
}),
|
||||
),
|
||||
).rejects.toBeInstanceOf(AuthorizationError);
|
||||
});
|
||||
|
||||
it("returns a validation error for an invalid email queue", async () => {
|
||||
const response = await POST(createEvent({ emails: [{ type: "INVALID" }] }));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user