The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
rearrange tests
Steven Tey16c573e8447b
diff --git a/apps/web/tests/redirects/index.test.ts b/apps/web/tests/redirects/index.test.tsindex 07d72ca18b..4617a3c09b 100644--- a/apps/web/tests/redirects/index.test.ts+++ b/apps/web/tests/redirects/index.test.ts@@ -55,30 +55,30 @@ describe.runIf(env.CI)("Link Redirects", async () => {expect(response.status).toBe(302);});- test("with dub_client_reference_id", async () => {- const response = await fetch(`${h.baseUrl}/client_reference_id`, {+ test("with dub_id and via", async () => {+ const response = await fetch(`${h.baseUrl}/track-test`, {...fetchOptions,headers: {},});- // the location should contain `?client_reference_id=dub_id_` query param- expect(response.headers.get("location")).toMatch(- /client_reference_id=dub_id_[a-zA-Z0-9]+/,- );+ // the location should contain `?dub_id=` query param+ expect(response.headers.get("location")).toMatch(/dub_id=[a-zA-Z0-9]+/);+ // the location should contain `?via=track-test` query param+ expect(response.headers.get("location")).toMatch(/via=track-test/);expect(response.headers.get("x-powered-by")).toBe(poweredBy);expect(response.status).toBe(302);});- test("with dub_id and via", async () => {- const response = await fetch(`${h.baseUrl}/track-test`, {+ test("with dub_client_reference_id", async () => {+ const response = await fetch(`${h.baseUrl}/client_reference_id`, {...fetchOptions,headers: {},});- // the location should contain `?dub_id=` query param- expect(response.headers.get("location")).toMatch(/dub_id=[a-zA-Z0-9]+/);- // the location should contain `?via=track-test` query param- expect(response.headers.get("location")).toMatch(/via=track-test/);+ // the location should contain `?client_reference_id=dub_id_` query param+ expect(response.headers.get("location")).toMatch(+ /client_reference_id=dub_id_[a-zA-Z0-9]+/,+ );expect(response.headers.get("x-powered-by")).toBe(poweredBy);expect(response.status).toBe(302);});