From 43e271b144ed095c67cddedefe938eaeae6020cb Mon Sep 17 00:00:00 2001 From: david <58231312+davseby@users.noreply.github.com> Date: Fri, 4 Sep 2026 20:16:31 +0300 Subject: [PATCH] update mock endpoints --- web/app/components/DocumentHeader.nuxt.test.ts | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/web/app/components/DocumentHeader.nuxt.test.ts b/web/app/components/DocumentHeader.nuxt.test.ts index 27ccf4e3..545bdf49 100644 --- a/web/app/components/DocumentHeader.nuxt.test.ts +++ b/web/app/components/DocumentHeader.nuxt.test.ts @@ -283,12 +283,12 @@ describe("", { concurrent: false }, () => { mainOnly() const created = mockEndpoint( "POST", - `/api/documents/${DOC_ID}/branches`, + `http://test.local/auth-realtime/api/documents/${DOC_ID}/branches`, () => ({ branchId: DRAFT_BRANCH }), ) const updated = mockEndpoint( "PUT", - `/api/documents/${DOC_ID}/branches/${MAIN_BRANCH}`, + `http://test.local/auth-realtime/api/documents/${DOC_ID}/branches/${MAIN_BRANCH}`, () => ({}), ) const wrapper = await mountHeader() @@ -318,7 +318,7 @@ describe("", { concurrent: false }, () => { ) const updated = mockEndpoint( "PUT", - `/api/documents/${DOC_ID}/branches/${MAIN_BRANCH}`, + `http://test.local/auth-realtime/api/documents/${DOC_ID}/branches/${MAIN_BRANCH}`, () => ({}), ) const wrapper = await mountHeader() @@ -335,9 +335,13 @@ describe("", { concurrent: false }, () => { it("warns when the reviewability change fails", async ({ expect }) => { mainOnly() - mockEndpoint("POST", `/api/documents/${DOC_ID}/branches`, () => { - throw createError({ statusCode: 500 }) - }) + mockEndpoint( + "POST", + `http://test.local/auth-realtime/api/documents/${DOC_ID}/branches`, + () => { + throw createError({ statusCode: 500 }) + }, + ) const wrapper = await mountHeader() await openOptionsMenu(wrapper) @@ -355,7 +359,7 @@ describe("", { concurrent: false }, () => { mainOnly() const created = mockEndpoint( "POST", - `/api/documents/${DOC_ID}/branches`, + `http://test.local/auth-realtime/api/documents/${DOC_ID}/branches`, () => ({ branchId: DRAFT_BRANCH }), ) const wrapper = await mountHeader()