From dc50c7fc75db321daf65b0bebd87cb9727de3a7e Mon Sep 17 00:00:00 2001 From: Stanislav Kalashnik Date: Tue, 21 Sep 2021 23:23:32 +0300 Subject: [PATCH] run only db jest tests https://github.com/facebook/jest/issues/11438 --- package.json | 2 +- tests/config.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index d109d66..7cc5883 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "dev": "nodemon --watch ./src --ext js --trace-warnings --require dotenv/config src/index.js", "start": "NODE_ENV=production node ./src/index.js", "lint": "eslint ./src ./tests", - "jest": "NODE_OPTIONS='--experimental-vm-modules --require dotenv/config' FORTNOTES_HTTP_PORT=0 FORTNOTES_DB_STORAGE=:memory: npx jest --runInBand --config tests/config.js", + "jest": "NODE_OPTIONS='--experimental-vm-modules --require dotenv/config' FORTNOTES_HTTP_PORT=0 FORTNOTES_DB_STORAGE=:memory: npx jest --config tests/config.js", "test": "npm run lint && npm run jest", "erd": "node src/utils/erd.js" }, diff --git a/tests/config.js b/tests/config.js index f1c5cf8..d41d041 100644 --- a/tests/config.js +++ b/tests/config.js @@ -2,7 +2,7 @@ export default { verbose: true, - testMatch: ['**/tests/specs/*.js'], + testMatch: ['**/tests/specs/db.js'], globalSetup: '/setup.js', globalTeardown: '/teardown.js', transform: {},