Skip to content

Commit

Permalink
Upgrade dependencies; Fix median/mode end-to-end test
Browse files Browse the repository at this point in the history
  • Loading branch information
kzalite committed Oct 24, 2019
1 parent 83ad80b commit 43b3601
Show file tree
Hide file tree
Showing 6 changed files with 1,055 additions and 874 deletions.
2 changes: 1 addition & 1 deletion app/js/mcda-web.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ define([
'ngResource',
'page-title-service',
'patavi',
'rzModule'
'rzSlider'
];

var app = angular.module('elicit', dependencies);
Expand Down
4 changes: 3 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,9 @@ function initApp() {
app.use((error, request, response, next) => {
logger.error(JSON.stringify(error.message, null, 2));
if (error && error.type === signin.SIGNIN_ERROR) {
response.send(httpStatus.UNAUTHORIZED, 'login failed');
response
.status(httpStatus.UNAUTHORIZED)
.send('login failed');
} else {
response
.status(error.status || error.statusCode || httpStatus.INTERNAL_SERVER_ERROR)
Expand Down
82 changes: 41 additions & 41 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,26 +22,26 @@
"readmeFilename": "README.md",
"dependencies": {
"async": "~3.1.0",
"body-parser": "~1.18.3",
"body-parser": "~1.19.0",
"chai": "^4.2.0",
"connect-pg-simple": "^6.0.0",
"csurf": "~1.9.0",
"express": "~4.16.3",
"express-session": "~1.15.6",
"connect-pg-simple": "^6.0.1",
"csurf": "~1.10.0",
"express": "~4.17.1",
"express-session": "~1.17.0",
"helmet": "^3.21.2",
"http-status-codes": "^1.3.2",
"lodash": "~4.17.14",
"pg": "~7.4.3",
"proxyquire": "^2.1.0",
"pg": "~7.12.1",
"proxyquire": "^2.1.3",
"signin": "drugis/signin#0.1.3",
"sinon": "^7.3.2",
"sinon": "^7.5.0",
"startup-diagnostics": "drugis/startup-diagnostics#1.1.1",
"winston": "~3.0.0"
"winston": "~3.2.1"
},
"devDependencies": {
"@babel/core": "^7.1.2",
"@babel/preset-env": "^7.1.0",
"ajv": "^6.10.0",
"@babel/core": "^7.6.4",
"@babel/preset-env": "^7.6.3",
"ajv": "~6.10.2",
"angular": "~1.7.8",
"angular-animate": "~1.7.8",
"angular-cookies": "~1.7.8",
Expand All @@ -52,53 +52,53 @@
"angular-touch": "~1.7.8",
"angular-ui-router": "~1.0.23",
"angular1-templateurl-loader": "^1.0.0",
"angularjs-slider": "~6.6.1",
"babel-loader": "^8.0.4",
"angularjs-slider": "~7.0.0",
"babel-loader": "^8.0.6",
"bcrypt-cli": "^1.1.0",
"bowser": "2.7.0",
"c3": "~0.4.23",
"chai-spies": "^1.0.0",
"clean-webpack-plugin": "^0.1.19",
"clipboard": "~2.0.1",
"core-js": "^2.5.7",
"css-loader": "^1.0.0",
"clean-webpack-plugin": "^3.0.0",
"clipboard": "~2.0.4",
"core-js": "^3.3.3",
"css-loader": "^3.2.0",
"d3": "~3.5.6",
"error-reporting": "drugis/error-reporting#1.3.1",
"export-directive": "drugis/export-directive#1.2.3",
"file-loader": "^2.0.0",
"file-loader": "^4.2.0",
"font-awesome": "~4.7.0",
"foundation-sites": "~6.5.0-rc.2",
"geckodriver": "^1.18.0",
"foundation-sites": "~6.5.3",
"geckodriver": "^1.19.0",
"help-popup": "drugis/help-popup#0.5.0",
"html-loader": "^0.5.5",
"html-webpack-plugin": "^4.0.0-alpha",
"jasmine-core": "^3.2.1",
"jasmine-core": "^3.5.0",
"jquery": "~3.4.1",
"karma": "4.1.0",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage": "^1.1.2",
"karma-firefox-launcher": "~1.1.0",
"karma-jasmine": "~1.1.2",
"karma-junit-reporter": "~1.2.0",
"karma": "4.4.1",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage": "^2.0.1",
"karma-firefox-launcher": "~1.2.0",
"karma-jasmine": "~2.0.1",
"karma-junit-reporter": "~2.0.1",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^3.0.5",
"katex": "^0.10.0-rc.1",
"mini-css-extract-plugin": "^0.4.2",
"karma-webpack": "^4.0.2",
"katex": "^0.11.1",
"mini-css-extract-plugin": "^0.8.0",
"nightwatch": "^1.2.4",
"nvd3": "~1.8.6",
"optimize-css-assets-webpack-plugin": "^5.0.1",
"optimize-css-assets-webpack-plugin": "^5.0.3",
"page-title-service": "drugis/page-title-service#1.0.4",
"raw-loader": "^0.5.1",
"raw-loader": "~1.0.0",
"rights-management": "drugis/rights-management#1.0.4",
"selenium-server": "^3.141.59",
"style-loader": "^0.22.1",
"tocbot": "^4.3.2",
"uglifyjs-webpack-plugin": "^2.1.3",
"url-loader": "^1.1.1",
"vanilla-back-to-top": "^7.1.14",
"webpack": "^4.35.3",
"webpack-cli": "^3.1.0",
"webpack-merge": "^4.2.1"
"style-loader": "^1.0.0",
"tocbot": "^4.8.1",
"uglifyjs-webpack-plugin": "^2.2.0",
"url-loader": "^2.2.0",
"vanilla-back-to-top": "^7.2.1",
"webpack": "^4.41.2",
"webpack-cli": "^3.3.9",
"webpack-merge": "^4.2.2"
},
"resolutions": {
"handlebars": "^4.3.0",
Expand Down
13 changes: 1 addition & 12 deletions test/endToEnd/settingsTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,24 +293,13 @@ module.exports = {
},

'Switching between median and mode in deterministic tab': function(browser) {
var columnPath = '//*[@id="OS-weight"]';
var valueMedian;
var valueMode;

browser
.useXpath()
.click('//*[@id="deterministic-tab"]')
.getText(columnPath, function(result) {
valueMedian = parseFloat(result.value);
})
.click('//*[@id="settings-button"]')
.click('//*[@id="show-mode-radio"]')
.click('//*[@id="save-settings-button"]')
.waitForElementVisible('//*[@id="sensitivity-measurements-header"]')
.getText(columnPath, function(result) {
valueMode = parseFloat(result.value);
chai.expect(valueMedian).to.not.equal(valueMode);
});
.waitForElementVisible('//*[@id="sensitivity-measurements-header"]');

browser.useCss();
},
Expand Down
6 changes: 3 additions & 3 deletions webpack.common.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';
const path = require('path');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const CleanWebpackPlugin = require('clean-webpack-plugin');
const { CleanWebpackPlugin } = require('clean-webpack-plugin');
let basePath = path.join(__dirname, '/');
let fs = require('fs');
const MATOMO_VERSION = process.env.MATOMO_VERSION ? process.env.MATOMO_VERSION : 'Test';
Expand Down Expand Up @@ -30,7 +30,7 @@ let config = {
exclude: [/.*angular-foundation-6.*/] // uses $templatecache so dont replace
}, {
test: /\.html$/,
loader: 'raw-loader'
use: 'raw-loader'
}, {
test: /.(ttf|otf|eot|woff(2)?)(\?[a-z0-9]+)?$/,
use: [{
Expand Down Expand Up @@ -97,7 +97,7 @@ let config = {
chunks: ['error'],
matomo: fs.readFileSync(require.resolve(basePath + '/app/matomo'+ MATOMO_VERSION +'.html'))
}),
new CleanWebpackPlugin(['dist'])
new CleanWebpackPlugin()
],

optimization: {
Expand Down
Loading

0 comments on commit 43b3601

Please sign in to comment.