From 5bd4bcc3e3c99fcc46c28b5c8f1b269cec453715 Mon Sep 17 00:00:00 2001 From: Winnie Hellmann Date: Thu, 11 Jul 2019 11:13:01 +0000 Subject: [PATCH] Replace path with filename in Jest config --- jest.config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jest.config.js b/jest.config.js index 986b8465eef..e4ac71a1a17 100644 --- a/jest.config.js +++ b/jest.config.js @@ -19,7 +19,7 @@ let testMatch = ['/spec/frontend/**/*_spec.js', '/ee/spec/fron // workaround for eslint-import-resolver-jest only resolving in test files // see https://github.com/JoinColony/eslint-import-resolver-jest#note -const isESLint = module.parent.path.includes('/eslint-import-resolver-jest/'); +const isESLint = module.parent.filename.includes('/eslint-import-resolver-jest/'); if (isESLint) { testMatch = testMatch.map(path => path.replace('_spec.js', '')); }