Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-09-25 00:06:18 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-09-25 00:06:18 +0300
commit150effab274651b3a8d2041e64ced734d1f3a349 (patch)
tree7f887964a56bd15a87d58cd367ccc1fa45f98554 /jest.config.js
parent2ed368929ab5094fec5da8038f723463596a80cf (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'jest.config.js')
-rw-r--r--jest.config.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/jest.config.js b/jest.config.js
index 34581c6532a..43d68c60137 100644
--- a/jest.config.js
+++ b/jest.config.js
@@ -19,7 +19,8 @@ let testMatch = ['<rootDir>/spec/frontend/**/*_spec.js', '<rootDir>/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.filename.includes('/eslint-import-resolver-jest/');
+const { filename: parentModuleName } = module.parent;
+const isESLint = parentModuleName && parentModuleName.includes('/eslint-import-resolver-jest/');
if (isESLint) {
testMatch = testMatch.map(path => path.replace('_spec.js', ''));
}