From 3122ccf4e4a9c9407747bfa80659a57f5885c708 Mon Sep 17 00:00:00 2001 From: Timo K Date: Tue, 26 Aug 2025 18:10:08 +0200 Subject: [PATCH] dont use deprecated `defer` Signed-off-by: Timo K --- src/livekit/useECConnectionState.test.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/livekit/useECConnectionState.test.tsx b/src/livekit/useECConnectionState.test.tsx index 72324884..e71ceeae 100644 --- a/src/livekit/useECConnectionState.test.tsx +++ b/src/livekit/useECConnectionState.test.tsx @@ -93,8 +93,8 @@ describe("Leaking connection prevention", () => { test("Should cancel pending connections when the component is unmounted", async () => { const connectCall = vi.fn(); - const pendingConnection = defer(); - // let pendingDisconnection = defer() + const pendingConnection = Promise.withResolvers(); + // let pendingDisconnection = Promise.withResolvers() const disconnectMock = vi.fn(); const mockRoom = { @@ -141,8 +141,8 @@ describe("Leaking connection prevention", () => { test("Should cancel about to open but not yet opened connection", async () => { const createTracksCall = vi.fn(); - const pendingCreateTrack = defer(); - // let pendingDisconnection = defer() + const pendingCreateTrack = Promise.withResolvers(); + // let pendingDisconnection = Promise.withResolvers() const disconnectMock = vi.fn(); const connectMock = vi.fn();