Scheduling infrastructure for absolutely everyone.
fix: unit test flake (#25780)
Anik Dhabal Babucb2509683de9
diff --git a/packages/features/bookings/Booker/components/hooks/useInitialFormValues.test.ts b/packages/features/bookings/Booker/components/hooks/useInitialFormValues.test.tsindex 14322d34878..f358cd603a7 100644--- a/packages/features/bookings/Booker/components/hooks/useInitialFormValues.test.ts+++ b/packages/features/bookings/Booker/components/hooks/useInitialFormValues.test.ts@@ -1,8 +1,8 @@/*** @vitest-environment jsdom*/-import { renderHook, waitFor } from "@testing-library/react";-import { describe, it, expect, vi, beforeEach } from "vitest";+import { cleanup, renderHook, waitFor } from "@testing-library/react";+import { describe, it, expect, vi, beforeEach, afterEach } from "vitest";import type { BookerEvent } from "@calcom/features/bookings/types";@@ -49,6 +49,10 @@ describe("useInitialFormValues - Autofill Disable Feature", () => {vi.clearAllMocks();});+ afterEach(() => {+ cleanup();+ });+describe("when organization has NOT disabled autofill", () => {it("should use URL parameters to prefill form fields", async () => {const eventType: Pick<BookerEvent, "bookingFields" | "team" | "owner"> = {