diff --git a/packages/server/src/app.ts b/packages/server/src/app.ts index 177393dee7..50a1e187ba 100644 --- a/packages/server/src/app.ts +++ b/packages/server/src/app.ts @@ -74,7 +74,7 @@ server.on("close", async () => { await events.shutdown() await Thread.shutdown() api.shutdown() - if (!env.isTest()) { + if (!env.isTest() && !env.isDockerisedTest()) { process.exit(errCode) } }) diff --git a/packages/server/src/environment.ts b/packages/server/src/environment.ts index d11661ce27..99949feb41 100644 --- a/packages/server/src/environment.ts +++ b/packages/server/src/environment.ts @@ -115,6 +115,7 @@ const environment = { isInThread: () => { return inThread }, + isDockerisedTest, } // threading can cause memory issues with node-ts in development