Merge pull request #1331 from sharelatex/as-publish-modal-tests

Publish modal tests

GitOrigin-RevId: 7e068ce05c02d61793419a5344501ca0ea51ed5f
This commit is contained in:
Simon Detheridge 2019-01-11 14:16:23 +00:00 committed by sharelatex
parent 97d6f81d7c
commit 8717ddffad
2 changed files with 22 additions and 4 deletions

View file

@ -43,11 +43,28 @@ module.exports = function (config) {
frameworks: ['requirejs', 'mocha', 'chai-sinon'],
// Configure webpack in the tests
webpack: {
module: {
rules: [{
// Pass application JS files through babel-loader, compiling to ES5
test: /\.js$/,
// Only compile application files (dependencies are in ES5 already)
exclude: /node_modules/,
use: [{
loader: 'babel-loader',
options: {
// Configure babel-loader to cache compiled output so that subsequent
// compile runs are much faster
cacheDirectory: true
}
}]
}]
},
resolve: {
// Alias common directories in import pathnames to cut down on the
// amount of ../../ etc
alias: {
// Alias Src in import pathnames to public/es
// Cuts down on the amount of ../../ etc
Src: path.join(__dirname, 'public/es/')
Src: path.join(__dirname, 'public/es/'),
Modules: path.join(__dirname, 'modules')
}
}
},

View file

@ -115,7 +115,7 @@
"babel-preset-react": "^6.16.0",
"bunyan": "0.22.1",
"chai": "3.5.0",
"chai-spies": "",
"chai-spies": "^1.0.0",
"clean-css-cli": "^4.2.1",
"coffee-script": "^1.7.1",
"es6-promise": "^4.0.5",
@ -166,6 +166,7 @@
"mkdirp": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
"nodemon": "^1.14.3",
"prettier-eslint-cli": "^4.7.1",
"react-testing-library": "^5.4.2",
"requirejs": "^2.1.22",
"sandboxed-module": "0.2.0",
"sinon": "^1.17.0",