Skip to content

Bump node.js to v6 LTS #1061

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Oct 21, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ We use the following [labels](https://github.com/plotly/plotly.js/labels) to tra
#### Perequisites

- git
- [node.js](https://nodejs.org/en/). We recommend using node.js 4.2.x (LTS).
- [node.js](https://nodejs.org/en/). We recommend using node.js v6.x or v4.x (both LTS).
Upgrading and managing node versions can be easily done using
[`nvm`](https://github.com/creationix/nvm) or its Windows alternatives.

Expand Down
2 changes: 1 addition & 1 deletion circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ general:

machine:
node:
version: 4.2.1
version: 6.1.0
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Unfortunately, this is the best we can do at the moment on CircleCI: https://circleci.com/docs/build-image-trusty/#nodejs

services:
- docker

Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"test-export": "node tasks/test_export.js",
"test-syntax": "node tasks/test_syntax.js",
"test-bundle": "node tasks/test_bundle.js",
"test": "npm run citest-jasmine && npm run test-image && npm run test-syntax && npm run test-bundle",
"test": "npm run citest-jasmine && npm run test-image && npm run test-image-gl2d && npm run test-syntax && npm run test-bundle",
"start-test_dashboard": "node devtools/test_dashboard/server.js",
"start-image_viewer": "node devtools/image_viewer/server.js",
"start": "npm run start-test_dashboard",
Expand Down Expand Up @@ -96,9 +96,9 @@
"browserify": "^13.0.0",
"browserify-transform-tools": "^1.5.1",
"deep-equal": "^1.0.1",
"ecstatic": "^1.4.0",
"ecstatic": "^2.1.0",
"eslint": "^3.5.0",
"falafel": "^1.2.0",
"falafel": "^2.0.0",
"fs-extra": "^0.30.0",
"fuse.js": "^2.2.0",
"glob": "^7.0.0",
Expand All @@ -107,11 +107,11 @@
"jasmine-core": "^2.4.1",
"karma": "^1.1.0",
"karma-browserify": "^5.0.1",
"karma-chrome-launcher": "^1.0.1",
"karma-chrome-launcher": "^2.0.0",
"karma-coverage": "^1.0.0",
"karma-firefox-launcher": "^1.0.0",
"karma-jasmine": "^1.0.2",
"madge": "^0.6.0",
"madge": "^1.4.3",
"node-sass": "^3.4.1",
"npm-link-check": "^1.1.0",
"open": "0.0.5",
Expand Down
23 changes: 12 additions & 11 deletions tasks/test_syntax.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,20 +98,21 @@ function assertFileNames() {

// check circular dependencies
function assertCircularDeps() {
var dependencyObject = madge(constants.pathToSrc);
var circularDeps = dependencyObject.circular().getArray();
var logs = [];
madge(constants.pathToSrc).then(function(res) {
var circularDeps = res.circular();
var logs = [];

// as of v1.17.0 - 2016/09/08
// see https://github.com/plotly/plotly.js/milestone/9
// for more details
var MAX_ALLOWED_CIRCULAR_DEPS = 34;
// as of v1.17.0 - 2016/09/08
// see https://github.com/plotly/plotly.js/milestone/9
// for more details
var MAX_ALLOWED_CIRCULAR_DEPS = 34;

if(circularDeps.length > MAX_ALLOWED_CIRCULAR_DEPS) {
logs.push('some new circular dependencies were added to src/');
}
if(circularDeps.length > MAX_ALLOWED_CIRCULAR_DEPS) {
logs.push('some new circular dependencies were added to src/');
}

log('circular dependencies', logs);
log('circular dependencies', logs);
});
}

function combineGlobs(arr) {
Expand Down
6 changes: 2 additions & 4 deletions test/jasmine/tests/mapbox_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,11 +448,9 @@ describe('mapbox plots', function() {
expect(mapInfo.zoom).toBeCloseTo(zoom);

var divStyle = mapInfo.div.style;
var expectedDims = ['left', 'top', 'width', 'height'].map(function(p) {
return parseFloat(divStyle[p]);
['left', 'top', 'width', 'height'].forEach(function(p, i) {
expect(parseFloat(divStyle[p])).toBeWithin(dims[i], 5);
});

expect(expectedDims).toBeCloseToArray(dims);
}

assertLayout('Mapbox Dark', [-4.710, 19.475], 1.234, [80, 100, 908, 270]);
Expand Down