From edd503b6161ac0fc07afec0d1c2b002762eeaebe Mon Sep 17 00:00:00 2001 From: Logan Nguyen Date: Tue, 9 Apr 2024 16:23:21 -0400 Subject: [PATCH] fix: removed timer after connecting and disconnecting wsProvider Signed-off-by: Logan Nguyen Revert "fix: removed timer after connecting and disconnecting wsProvider" This reverts commit 8cc42b8f244dd560c22f61d33f96fda45e4a4d8d. a Signed-off-by: Logan Nguyen --- packages/server/tests/acceptance/ws/estimateGas.spec.ts | 1 - packages/server/tests/acceptance/ws/getCode.spec.ts | 1 - .../server/tests/acceptance/ws/getTransactionByHash.spec.ts | 2 -- .../server/tests/acceptance/ws/getTransactionReceipt.spec.ts | 2 -- packages/server/tests/acceptance/ws/sendRawTransaction.spec.ts | 2 -- 5 files changed, 8 deletions(-) diff --git a/packages/server/tests/acceptance/ws/estimateGas.spec.ts b/packages/server/tests/acceptance/ws/estimateGas.spec.ts index f6436da35e..03233cb8ba 100644 --- a/packages/server/tests/acceptance/ws/estimateGas.spec.ts +++ b/packages/server/tests/acceptance/ws/estimateGas.spec.ts @@ -61,7 +61,6 @@ describe('@release @web-socket eth_estimateGas', async function () { afterEach(async () => { if (wsProvider) { await wsProvider.destroy(); - await new Promise((resolve) => setTimeout(resolve, 1000)); } }); diff --git a/packages/server/tests/acceptance/ws/getCode.spec.ts b/packages/server/tests/acceptance/ws/getCode.spec.ts index 8804207f16..73841a06e4 100644 --- a/packages/server/tests/acceptance/ws/getCode.spec.ts +++ b/packages/server/tests/acceptance/ws/getCode.spec.ts @@ -53,7 +53,6 @@ describe('@release @web-socket eth_getCode', async function () { afterEach(async () => { if (wsProvider) { await wsProvider.destroy(); - await new Promise((resolve) => setTimeout(resolve, 1000)); } }); diff --git a/packages/server/tests/acceptance/ws/getTransactionByHash.spec.ts b/packages/server/tests/acceptance/ws/getTransactionByHash.spec.ts index cc01e058b9..4324e36559 100644 --- a/packages/server/tests/acceptance/ws/getTransactionByHash.spec.ts +++ b/packages/server/tests/acceptance/ws/getTransactionByHash.spec.ts @@ -50,13 +50,11 @@ describe('@release @web-socket eth_getTransactionByHash', async function () { beforeEach(async () => { wsProvider = new ethers.WebSocketProvider(WS_RELAY_URL); - await new Promise((resolve) => setTimeout(resolve, 1000)); }); afterEach(async () => { if (wsProvider) { await wsProvider.destroy(); - await new Promise((resolve) => setTimeout(resolve, 1000)); } }); diff --git a/packages/server/tests/acceptance/ws/getTransactionReceipt.spec.ts b/packages/server/tests/acceptance/ws/getTransactionReceipt.spec.ts index c4313fd2cf..8ce0d1561e 100644 --- a/packages/server/tests/acceptance/ws/getTransactionReceipt.spec.ts +++ b/packages/server/tests/acceptance/ws/getTransactionReceipt.spec.ts @@ -50,13 +50,11 @@ describe('@release @web-socket eth_getTransactionReceipt', async function () { beforeEach(async () => { wsProvider = new ethers.WebSocketProvider(WS_RELAY_URL); - await new Promise((resolve) => setTimeout(resolve, 1000)); }); afterEach(async () => { if (wsProvider) { await wsProvider.destroy(); - await new Promise((resolve) => setTimeout(resolve, 1000)); } }); diff --git a/packages/server/tests/acceptance/ws/sendRawTransaction.spec.ts b/packages/server/tests/acceptance/ws/sendRawTransaction.spec.ts index 88569f6051..507b97e6c2 100644 --- a/packages/server/tests/acceptance/ws/sendRawTransaction.spec.ts +++ b/packages/server/tests/acceptance/ws/sendRawTransaction.spec.ts @@ -50,13 +50,11 @@ describe('@release @web-socket eth_sendRawTransaction', async function () { beforeEach(async () => { wsProvider = new ethers.WebSocketProvider(WS_RELAY_URL); - await new Promise((resolve) => setTimeout(resolve, 1000)); }); afterEach(async () => { if (wsProvider) { await wsProvider.destroy(); - await new Promise((resolve) => setTimeout(resolve, 1000)); } });