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
path: root/config
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2019-05-07 10:45:42 +0300
committerPhil Hughes <me@iamphill.com>2019-05-07 10:45:42 +0300
commit06b06736eb314bf4144ae50400fbe9d8f8f3cae7 (patch)
treee7db2052049b3cd9ed9a8c7d50616383ce58c5ef /config
parent2cbfd5c58cfcfe43dbaee3e6734bdf5fff9105b9 (diff)
parentfbac16b2de4b715a85dfd2b79768079d12229bc1 (diff)
Merge branch 'winh-separate-frontend-fixtures' into 'master'
Generate EE-specific JavaScript fixtures into ee/ directory (CE-backport) See merge request gitlab-org/gitlab-ce!28032
Diffstat (limited to 'config')
-rw-r--r--config/karma.config.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/config/karma.config.js b/config/karma.config.js
index dfcb5c4646e..83ba46345f2 100644
--- a/config/karma.config.js
+++ b/config/karma.config.js
@@ -4,6 +4,7 @@ const chalk = require('chalk');
const webpack = require('webpack');
const argumentsParser = require('commander');
const webpackConfig = require('./webpack.config.js');
+const IS_EE = require('./helpers/is_ee_env');
const ROOT_PATH = path.resolve(__dirname, '..');
const SPECS_PATH = /^(?:\.[\\\/])?(ee[\\\/])?spec[\\\/]javascripts[\\\/]/;
@@ -90,6 +91,8 @@ if (specFilters.length) {
module.exports = function(config) {
process.env.TZ = 'Etc/UTC';
+ const fixturesPath = `${IS_EE ? 'ee/' : ''}spec/javascripts/fixtures`;
+
const karmaConfig = {
basePath: ROOT_PATH,
browsers: ['ChromeHeadlessCustom'],
@@ -110,7 +113,7 @@ module.exports = function(config) {
frameworks: ['jasmine'],
files: [
{ pattern: 'spec/javascripts/test_bundle.js', watched: false },
- { pattern: `spec/javascripts/fixtures/**/*@(.json|.html|.png|.bmpr|.pdf)`, included: false },
+ { pattern: `${fixturesPath}/**/*@(.json|.html|.png|.bmpr|.pdf)`, included: false },
],
preprocessors: {
'spec/javascripts/**/*.js': ['webpack', 'sourcemap'],