From 329f774dc91cdc85991b18be37e5a896c9624372 Mon Sep 17 00:00:00 2001 From: HDegroote <75906619+HDegroote@users.noreply.github.com> Date: Mon, 8 Apr 2024 22:30:02 +0200 Subject: [PATCH 1/2] Add more time before timeout on request --- test/end-to-end-tests.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/end-to-end-tests.js b/test/end-to-end-tests.js index 9e79f99..21eb1e0 100644 --- a/test/end-to-end-tests.js +++ b/test/end-to-end-tests.js @@ -125,7 +125,7 @@ async function setupHyperteleClient (seed, bootstrap, t, { isPrivate = false } = return clientPort } -async function request (port, { msTimeout = 500 } = {}) { +async function request (port, { msTimeout = 5000 } = {}) { const link = `http://127.0.0.1:${port}` return new Promise((resolve, reject) => { From a19f646deb7bda67c0344eae7bfc3dad3730d900 Mon Sep 17 00:00:00 2001 From: HDegroote <75906619+HDegroote@users.noreply.github.com> Date: Mon, 8 Apr 2024 23:02:53 +0200 Subject: [PATCH 2/2] Fix test: 1000ms timeout for the test with expected timeout --- test/end-to-end-tests.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/end-to-end-tests.js b/test/end-to-end-tests.js index 21eb1e0..04ce235 100644 --- a/test/end-to-end-tests.js +++ b/test/end-to-end-tests.js @@ -34,7 +34,7 @@ test('Cannot access private-mode server with public key', async t => { const clientPort = await setupHyperteleClient(pubKey, bootstrap, t, { isPrivate: false }) // Could also be a socket hangup if more time is given - await t.exception(async () => await request(clientPort), /Request timeout/) + await t.exception(async () => await request(clientPort, { msTimeout: 1000 }), /Request timeout/) }) test('Can proxy in non-private mode', async t => {