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:
authorWinnie Hellmann <winnie@gitlab.com>2018-08-29 23:45:53 +0300
committerWinnie Hellmann <winnie@gitlab.com>2018-12-05 11:24:42 +0300
commita8a13d3259374a1b25ca4a3e954bca563a66a532 (patch)
treefd579414080576ea8fa0305645d29d325372f6f2 /.babelrc.js
parent8cd5004b350ef342f66956c11272dad1328f6526 (diff)
Setup Jest test environment
Diffstat (limited to '.babelrc.js')
-rw-r--r--.babelrc.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/.babelrc.js b/.babelrc.js
index 27caf378b99..bfcc7d96634 100644
--- a/.babelrc.js
+++ b/.babelrc.js
@@ -35,4 +35,10 @@ if (BABEL_ENV === 'karma' || BABEL_ENV === 'coverage') {
plugins.push('babel-plugin-rewire');
}
+// Jest is running in node environment
+if (BABEL_ENV === 'jest') {
+ plugins.push('transform-es2015-modules-commonjs');
+ plugins.push('dynamic-import-node');
+}
+
module.exports = { presets, plugins };