chore: parallelize integration tests and use template dbs (#907)

This commit is contained in:
Zakaria El Asri
2021-12-14 21:45:57 +01:00
committed by GitHub
parent b8ff364276
commit 69620e572e
12 changed files with 171 additions and 69 deletions

View File

@@ -12,5 +12,9 @@ const pgGodCredentials = {
}
afterAll(() => {
dropDatabase({ databaseName: "medusa-integration" }, pgGodCredentials)
const workerId = parseInt(process.env.JEST_WORKER_ID || "1")
dropDatabase(
{ databaseName: `medusa-integration-${workerId}` },
pgGodCredentials
)
})