From c03ca5549f80bb1142b0dfe33574c3ad54c9009f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Omar=20L=C3=B3pez?= Date: Sun, 24 Jul 2022 14:18:36 -0600 Subject: [PATCH] Wipe my cal e2e fixes (#3509) Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com> --- .../{lib/appstore => }/wipe-my-cal.test.ts | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) rename apps/web/playwright/{lib/appstore => }/wipe-my-cal.test.ts (83%) diff --git a/apps/web/playwright/lib/appstore/wipe-my-cal.test.ts b/apps/web/playwright/wipe-my-cal.test.ts similarity index 83% rename from apps/web/playwright/lib/appstore/wipe-my-cal.test.ts rename to apps/web/playwright/wipe-my-cal.test.ts index 934237b672..edb018fbc9 100644 --- a/apps/web/playwright/lib/appstore/wipe-my-cal.test.ts +++ b/apps/web/playwright/wipe-my-cal.test.ts @@ -3,7 +3,7 @@ import { expect } from "@playwright/test"; import dayjs from "@calcom/dayjs"; import prisma from "@calcom/prisma"; -import { test } from "../../lib/fixtures"; +import { test } from "./lib/fixtures"; test.describe.configure({ mode: "parallel" }); @@ -31,15 +31,6 @@ test.describe("Wipe my Cal App Test", () => { dayjs().endOf("day").subtract(29, "minutes").toDate(), dayjs().endOf("day").toDate() ); - await prisma.credential.create({ - data: { - key: {}, - type: "wipemycal_other", - userId: pro.id, - appId: "wipe-my-cal", - }, - }); - await bookings.create(pro.id, pro.username, eventType.id, {}); await bookings.create(pro.id, pro.username, eventType.id, {}); await pro.login(); @@ -51,7 +42,7 @@ test.describe("Wipe my Cal App Test", () => { userId: pro.id, }, }); - expect(totalUserBookings?.length).toBe(3); + expect(totalUserBookings.length).toBe(3); await page.locator("data-testid=wipe-today-button").click(); await page.locator("data-testid=send_request").click(); // eslint-disable-next-line playwright/no-wait-for-timeout @@ -63,7 +54,7 @@ test.describe("Wipe my Cal App Test", () => { }, }); - await expect(totalUserBookingsCancelled?.length).toBe(1); + expect(totalUserBookingsCancelled.length).toBe(1); await users.deleteAll(); }); });