From 0c064a9d45fe2c21de9a060a881bfa6e6976c363 Mon Sep 17 00:00:00 2001 From: Jordan Ribbink Date: Fri, 22 Nov 2024 12:57:52 -0800 Subject: [PATCH] prettier --- .../src/subscriptions/stream-controller.test.ts | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/packages/transport-http/src/subscriptions/stream-controller.test.ts b/packages/transport-http/src/subscriptions/stream-controller.test.ts index 9527ee7cf..5468854fa 100644 --- a/packages/transport-http/src/subscriptions/stream-controller.test.ts +++ b/packages/transport-http/src/subscriptions/stream-controller.test.ts @@ -14,6 +14,15 @@ jest.mock("../websocket", () => ({ })) describe("StreamController", () => { + let mockWs: WS + beforeEach(() => { + mockWs = new WS("wss://localhost:8080") + }) + + afterEach(() => { + WS.clean() + }) + test("constructor", () => { const config = { hostname: "hostname", @@ -36,8 +45,6 @@ describe("StreamController", () => { const onData = jest.fn() const onError = jest.fn() - const mockWs = new WS("wss://localhost:8080") - let serverPromise = (async () => { await mockWs.connected @@ -110,8 +117,6 @@ describe("StreamController", () => { const onData = jest.fn() const onError = jest.fn() - let mockWs = new WS("wss://localhost:8080") - let serverPromise = (async () => { await mockWs.connected