Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

fix tests

Steven Teyb1075a180db0
diff --git a/apps/web/playwright/api/customers/customers-reattribute.spec.ts b/apps/web/playwright/api/customers/customers-reattribute.spec.ts
index bb2c6297e1..6738dd623c 100644
--- a/apps/web/playwright/api/customers/customers-reattribute.spec.ts
+++ b/apps/web/playwright/api/customers/customers-reattribute.spec.ts
@@ -36,7 +36,7 @@ test("POST /customers/{id}/reattribute – unknown customer", async ({ api }) =>
);
});
-test("POST /customers/{id}/reattribute – unchanged partner and link", async ({
+test("POST /customers/{id}/reattribute – unchanged partner", async ({
api,
program,
}) => {
@@ -72,7 +72,7 @@ test("POST /customers/{id}/reattribute – unchanged partner and link", async ({
).toEqual(
apiError({
code: "bad_request",
- message: "Customer is already attributed to this partner and link.",
+ message: `Customer "${created.id}" is already attributed to the partner "${partner.id}".`,
}),
);
} finally {
@@ -114,8 +114,7 @@ test("POST /customers/{id}/reattribute – retired stub", async ({ api }) => {
).toEqual(
apiError({
code: "bad_request",
- message:
- "This customer was already reattributed. Use the new customer ID.",
+ message: `Customer "${created.id}" was already reattributed. Use the new customer ID instead.`,
}),
);
} finally {
diff --git a/apps/web/tests/workflows/reattribute-customer-workflow.test.ts b/apps/web/tests/workflows/reattribute-customer-workflow.test.ts
index 990684e620..adea2e08d7 100644
--- a/apps/web/tests/workflows/reattribute-customer-workflow.test.ts
+++ b/apps/web/tests/workflows/reattribute-customer-workflow.test.ts
@@ -189,7 +189,7 @@ describe.sequential("Workflow - ReattributeCustomer", async () => {
);
test(
- "Reattributing to the same partner and link is rejected",
+ "Reattributing to the same partner is rejected",
{ timeout: VITEST_TEST_TIMEOUT_MS },
async () => {
const partner = await createEnrolledPartner("noop");
@@ -218,7 +218,7 @@ describe.sequential("Workflow - ReattributeCustomer", async () => {
expect(data).toMatchObject({
error: {
code: "bad_request",
- message: "Customer is already attributed to this partner and link.",
+ message: `Customer "${customer.id}" is already attributed to the partner "${partner.id}".`,
},
});
},