diff --git a/test/e2e/lib/framework/httpServers.ts b/test/e2e/lib/framework/httpServers.ts index 6d511c3123..d71971c274 100644 --- a/test/e2e/lib/framework/httpServers.ts +++ b/test/e2e/lib/framework/httpServers.ts @@ -86,7 +86,7 @@ async function instantiateServer(): Promise { try { return await instantiateServerOnPort(port) } catch (error) { - if (error instanceof Error && (error as NodeJS.ErrnoException).code === 'EADDRINUSE') { + if ((error as NodeJS.ErrnoException).code === 'EADDRINUSE') { continue } throw error