From 1bf5cf41e124cbd0ce6ec86cc0860d925524c6d9 Mon Sep 17 00:00:00 2001 From: "Carlos R. L. Rodrigues" Date: Thu, 14 Nov 2024 11:46:42 -0300 Subject: [PATCH] jest ignore .medusa folder --- jest.config.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/jest.config.js b/jest.config.js index a5175f1f..4600ebd7 100644 --- a/jest.config.js +++ b/jest.config.js @@ -1,5 +1,5 @@ -const { loadEnv } = require('@medusajs/utils') -loadEnv('test', process.cwd()) +const { loadEnv } = require("@medusajs/utils"); +loadEnv("test", process.cwd()); module.exports = { transform: { @@ -14,13 +14,13 @@ module.exports = { }, testEnvironment: "node", moduleFileExtensions: ["js", "ts", "json"], - modulePathIgnorePatterns: ["dist/"], -} + modulePathIgnorePatterns: ["dist/", "/.medusa/"], +}; if (process.env.TEST_TYPE === "integration:http") { - module.exports.testMatch = ["**/integration-tests/http/*.spec.[jt]s"] + module.exports.testMatch = ["**/integration-tests/http/*.spec.[jt]s"]; } else if (process.env.TEST_TYPE === "integration:modules") { - module.exports.testMatch = ["**/src/modules/*/__tests__/**/*.[jt]s"] + module.exports.testMatch = ["**/src/modules/*/__tests__/**/*.[jt]s"]; } else if (process.env.TEST_TYPE === "unit") { - module.exports.testMatch = ["**/src/**/__tests__/**/*.unit.spec.[jt]s"] -} \ No newline at end of file + module.exports.testMatch = ["**/src/**/__tests__/**/*.unit.spec.[jt]s"]; +}