mirror of
https://github.com/open-reception/appointment-booking-software.git
synced 2026-09-12 12:17:39 +02:00
Fix tests
This commit is contained in:
+1
@@ -36,6 +36,7 @@ describe("Create New Client API Route", () => {
|
||||
channelId: mockChannelId,
|
||||
agentId: "agent-123", // Missing field added
|
||||
appointmentDate: "2024-12-25T14:30:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 10,
|
||||
emailHash: "test-email-hash",
|
||||
clientEmail: "test@example.com",
|
||||
|
||||
@@ -68,6 +68,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
clientEmail: "test@example.com",
|
||||
emailHash,
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
@@ -108,6 +109,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
emailHash,
|
||||
clientEmail: "test@example.com",
|
||||
@@ -151,6 +153,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
hasNoEmail: true,
|
||||
emailHash: "unique-hash-for-no-email",
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
@@ -214,6 +217,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
clientEmail: "existing@example.com",
|
||||
emailHash,
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
@@ -245,6 +249,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
clientEmail: "existing@example.com",
|
||||
clientLanguage: "de",
|
||||
@@ -291,6 +296,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
clientEmail: "test@example.com",
|
||||
emailHash,
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
@@ -387,6 +393,7 @@ describe("POST /api/tenants/[id]/appointments/staff-create", () => {
|
||||
body: JSON.stringify({
|
||||
emailHash,
|
||||
appointmentDate: "2026-01-15T14:00:00.000Z",
|
||||
appointmentTimeZone: "Europe/Berlin",
|
||||
duration: 30,
|
||||
channelId: "channel-123",
|
||||
agentId: "agent-123",
|
||||
|
||||
Reference in New Issue
Block a user