Skip to content
This repository has been archived by the owner on Jul 29, 2019. It is now read-only.

Upgrade packages and tools for Travis unit testing #3262

Merged
merged 11 commits into from
Jul 16, 2017
1 change: 1 addition & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,6 @@
"no-redeclare": 0,
"no-unreachable": 1,
"no-unused-vars": 0,
"no-useless-escape": 0,
}
}
12 changes: 11 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
language: node_js
node_js: "6"
node_js:
- "6"
env:
- CXX=g++-4.8
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- libgif-dev
- g++-4.8
before_script:
- npm run lint
- npm install -g gulp
Expand Down
5 changes: 3 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ var argv = require('yargs').argv;

var ENTRY = './index.js';
var HEADER = './lib/header.js';
var DIST = './dist';
var DIST = __dirname + '/dist';
var VIS_JS = 'vis.js';
var VIS_MAP = 'vis.map';
var VIS_MIN_JS = 'vis.min.js';
Expand All @@ -38,7 +38,8 @@ function createBanner() {
.replace('@@version', version);
}

var bannerPlugin = new webpack.BannerPlugin(createBanner(), {
var bannerPlugin = new webpack.BannerPlugin({
banner: createBanner(),
entryOnly: true,
raw: true
});
Expand Down
2 changes: 1 addition & 1 deletion lib/network/modules/ManipulationSystem.js
Original file line number Diff line number Diff line change
Expand Up @@ -1077,8 +1077,8 @@ class ManipulationSystem {
});
}
else {
throw new Error('The function for add does not support two arguments (data,callback)');
this.showManipulatorToolbar();
throw new Error('The function for add does not support two arguments (data,callback)');
}
}
else {
Expand Down
13 changes: 10 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
"type": "git",
"url": "git://github.com/almende/vis.git"
},
"bugs": {
"url": "https://github.com/almende/vis/issues"
},
"keywords": [
"vis",
"visualization",
Expand Down Expand Up @@ -48,21 +51,25 @@
"babel-preset-es2015": "^6.6.0",
"babel-runtime": "^6.22.0",
"babelify": "^7.3.0",
"canvas": "^1.6.5",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wimrijnders What do we need this for? This module requires Cairo wich is an unacceptable external dependency. Since this I can not install vis anymore on linux 😭

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

canvas is used to run unit tests on Network. Why is cairo an unacceptable external dependency?

Copy link
Member

@mojoaxel mojoaxel Oct 2, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cairo can not be installed via npm and therefor adds a OS-specific dependency. How should the user (like me) know that he has to install g++ and libgif-dev? npm install now just fails. I personally think this is not acceptable!
We should not have dependencies other that npm (and maybe git) as far as I'm concerned.
The least thing would be to document this in the README.

Copy link
Member

@mojoaxel mojoaxel Oct 2, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've created an issue for that: #3515 Lets discuss over there, what the best way is to solve this.

"clean-css": "^4.0.2",
"eslint": "^3.15.0",
"eslint": "^4.2.0",
"gulp": "^3.9.1",
"gulp-clean-css": "^2.3.2",
"gulp-clean-css": "^3.7.0",
"gulp-concat": "^2.6.1",
"gulp-eslint": "^4.0.0",
"gulp-rename": "^1.2.2",
"gulp-util": "^3.0.8",
"jsdom": "9.9.1",
"jsdom-global": "^2.1.1",
"merge-stream": "^1.0.0",
"mocha": "^3.2.0",
"mocha-jsdom": "^1.1.0",
"rimraf": "^2.5.4",
"test-console": "^1.0.0",
"uglify-js": "^2.7.5",
"uuid": "^3.0.1",
"webpack": "^1.14.0",
"webpack": "^2.0.0",
"yargs": "^6.6.0"
}
}