0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-29 23:16:30 +01:00
Commit Graph

544 Commits

Author SHA1 Message Date
Anatoli Papirovski
6f63f8d730
test: remove outdated, non-functioning test
The timers directory test, utilizing FakeTime, has not worked in
quite a while and is not truly testing Node.js behaviour. If a
similar test is necessary it would be better suited to libuv
on which Node.js relies for timers functionality.

PR-URL: https://github.com/nodejs/node/pull/20894
Fixes: https://github.com/nodejs/node/issues/10154
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
2018-06-24 21:34:59 -07:00
Daniel Bevenius
6ced651b6c build: add crypto check to markdown lint target
Currently, if configured --without-ssl the following error will be
repored by remark-cli:

Running Markdown linter on misc docs...
internal/util.js:100
    throw new ERR_NO_CRYPTO();
    ^

Error [ERR_NO_CRYPTO]: Node.js is not compiled with OpenSSL crypto support
    at assertCrypto (internal/util.js💯11)
    at crypto.js:31:1
    at NativeModule.compile (internal/bootstrap/loaders.js:235:7)
    at Function.NativeModule.require
      (internal/bootstrap/loaders.js:155:18)
    at Function.Module._load (internal/modules/cjs/loader.js:530:25)
    at Module.require (internal/modules/cjs/loader.js:650:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous>
      (/node/tools/remark-cli/node_modules/math-random/node.js:1:76)
    at Module._compile (internal/modules/cjs/loader.js:702:30)
    at Object.Module._extensions..js
      (internal/modules/cjs/loader.js:713:10)
make[1]: *** [tools/.miscmdlintstamp] Error 1
make: *** [lint] Error 2

This commit adds a check for crypto to avoid this error when node has
been configured without crypto support. The alternative was to try to
fix this in randomatic but that lead to another dependency failing
(uuid) and felt like this might be simpler.

PR-URL: https://github.com/nodejs/node/pull/21326
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-06-24 06:47:37 +02:00
Rich Trott
d10742d891 benchmark: create napi benchmark directory
Move C++ benchmark useful for NAPI to its own directory. This will
isolate the benchmark so it can be excluded from testing that applies to
all other benchmarks but not this one.

PR-URL: https://github.com/nodejs/node/pull/21046
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2018-06-19 10:37:38 -07:00
Rich Trott
ff00a765dc tools: lint doc/*.md files
Makefile tasks only lint doc/**/*.md files but omit files that match
doc/*.md. This change adds these previously-omitted files to the list of
files to be linted.

PR-URL: https://github.com/nodejs/node/pull/21361
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-06-16 07:54:34 -07:00
Anna Henningsen
cea10baa22
build: build addon tests in parallel
Use a JS script to build addons rather than a shell command
embedded in the Makefile, because parallelizing is hard in sh
and easy in JS.

PR-URL: https://github.com/nodejs/node/pull/21155
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-06-11 20:09:28 +02:00
Ujjwal Sharma
2237a8e45d build: stop distclean from deleting v8 files
Stop `make distclean` from deleting files in the `deps/v8/testing/gmock`
folder, thus avoiding deleting version-controlled files important for
v8.

Fixes: https://github.com/nodejs/node/issues/21163

PR-URL: https://github.com/nodejs/node/pull/21164
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2018-06-08 23:09:31 -07:00
Kenny Yuan
e41ccd4e2d n-api: improve runtime perf of n-api func call
Added a new struct CallbackBundle to eliminate all
GetInternalField() calls.

The principle is to store all required data inside a C++ struct,
and then store the pointer in the JavaScript object. Before this
change, the required data are stored in the JavaScript object in
3 or 4 seperate pointers. For every napi fun call, 3 of them
have to be fetched out, which are 3 GetInternalField() calls;
after this change, the C++ struct will be directly fetched out
by using v8::External::Value(), which is faster.

Profiling data show that GetInternalField() is slow.
On an i7-4770K (3.50GHz) box, a C++ V8-binding fun call is 8 ns,
before this change, napi fun call is 36 ns; after this change,
napi fun call is 20 ns.

The above data are measured using a modified benchmark in
'benchmark/misc/function_call'. The modification adds an indicator
of the average time of a "chatty" napi fun call (max 50M runs).
This change will speed up chatty case 1.8x (overall), and will cut
down the delay of napi mechanism to approx. 0.5x.

Background: a simple C++ binding function (e.g. receiving little
from JS, doing little and returning little to JS) is called
'chatty' case for JS<-->C++ fun call routine.

This improvement also applies to getter/setter fun calls.

PR-URL: https://github.com/nodejs/node/pull/21072
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
2018-06-07 22:56:20 -04:00
Matheus Marchini
e1fc52d9e6
test: create new directory v8-updates
`v8-updates` holds all tests related to V8 updates, for example, testing
for postmortem metadata chages.

PR-URL: https://github.com/nodejs/node/pull/20783
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2018-06-06 11:10:12 -07:00
Myles Borins
1aa582a97c
tools: ensure doc-only doesn't update package-lock
Currently `make doc-only` is updating the package-lock.json
which is breaking our release build.

This adds the flags `--no-package-lock` when
running `npm install` to ensure the package-lock.json is not
changed unintentionally by running make

PR-URL: https://github.com/nodejs/node/pull/21015
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-06-06 14:29:07 +02:00
Benjamin Coe
16377146b6
test: fix tests that fail under coverage
Make test runner capable of skipping tests, which makes it possible
to skip the failing test/message/core_line_numbers.js test.

Make nyc no longer generate compact instrumentation (this causes
significantly different code output, which leads to failing test
assertions).

PR-URL: https://github.com/nodejs/node/pull/20794
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2018-05-22 12:45:54 +04:00
Benjamin Coe
d5a117c73f
build: use nyc's merge command
a 'merge' command has recently been added to nyc, eliminating the need
for the istanbul-merge library.

PR-URL: https://github.com/nodejs/node/pull/20760
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-05-18 16:14:47 +02:00
Joyee Cheung
657723e5c0
build: always use BUILDTYPE binary to run JS tests
PR-URL: https://github.com/nodejs/node/pull/20362
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-05-14 21:53:50 +08:00
Ruben Bridgewater
c71b97303c
build: check for different deprecation signatures
Right now we strictly test for `DEP00XX`. We are already above that
number of deprecations and it is better to have a wildcard for the
first three numbers. Only the last character has to match the X to
print a warning.

PR-URL: https://github.com/nodejs/node/pull/20384
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2018-05-05 13:50:17 +02:00
Vse Mozhet Byt
ad6a65ba11 tools: simplify HTML generation
PR-URL: https://github.com/nodejs/node/pull/20307
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-28 00:52:25 +03:00
Rich Trott
7424d86523 build: use -9 with kill in Makefile
Fixes: https://github.com/nodejs/node/issues/20194

PR-URL: https://github.com/nodejs/node/pull/20195
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-04-24 11:47:03 -07:00
Chris Miller
8786889656
build: normalise test.py calls to use PARALLEL_ARGS
PR-URL: https://github.com/nodejs/node/pull/20124
Fixes: https://github.com/nodejs/node/issues/20065
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-04-23 16:00:51 +02:00
Michaël Zasso
3e6ff85894
tools: fix make test-v8
PR-URL: https://github.com/nodejs/node/pull/19201
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-04-11 13:23:27 -04:00
Joyee Cheung
dd49677096
build: update node.gyp to reference gypfiles/v8.gyp
Refs: f9934aa9cf
Fixes: https://github.com/nodejs/node-v8/issues/36

PR-URL: https://github.com/nodejs/node/pull/19201
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-04-11 13:23:19 -04:00
Joyee Cheung
2f8df6b0f2
build: introduce make jstest
Add a `make jstest` target that runs tests written in JavaScript
(excluding documentation tests which are run in `make test-doc`).

PR-URL: https://github.com/nodejs/node/pull/19324
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Matheus Marchini <matheus@sthima.com>
2018-04-04 13:45:34 +08:00
Rod Vagg
c5928ab631 build: make lint-ci work properly on Linux make
PR-URL: https://github.com/nodejs/node/pull/19746
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2018-04-03 20:44:29 +10:00
Rich Trott
f05eaa4a53
build: lint .eslintrc.js file
Update default files to be linted with ESLint to include .eslintrc.js.

PR-URL: https://github.com/nodejs/node/pull/19122
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-03-06 09:30:57 +01:00
Michael Dawson
29697ef3de build: fix gocvr version used for coverage
Fix the gcovr version to a fixed version and uses patches
specific to that version. This avoids us being broken by
changes in the gcovr repo. Using file name for patches
specific to the version level will allow us to move up when
necessary without breaking coverage for earlier versions
of Node.js

PR-URL: https://github.com/nodejs/node/pull/19094
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
2018-03-05 11:06:37 -05:00
killagu
3f78d3fcf8 build: fix coverage after gcovr update
PR-URL: https://github.com/nodejs/node/pull/18958
Fixes: https://github.com/nodejs/node/issues/18938
Ref: https://github.com/nodejs/build/pull/1145
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
2018-02-28 11:46:34 -05:00
Joyee Cheung
0bff955b6d
build: fix lint-md-build dependency
PR-URL: https://github.com/nodejs/node/pull/18981
Fixes: https://github.com/nodejs/node/issues/18978
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-02-27 18:56:46 +08:00
Gus Caplan
6934792eb3 lint: move eslint to new plugin system
PR-URL: https://github.com/nodejs/node/pull/18566
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
2018-02-20 13:13:22 -06:00
Joyee Cheung
b50571602a
build: do not suppress output in make doc-only
This helps to show the cause of errors in the CI.

PR-URL: https://github.com/nodejs/node/pull/18507
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-02-08 17:56:07 +08:00
Camilo Gonzalez
0548034272 build: add doc linting when runnning make lint
Fixes: https://github.com/nodejs/node/issues/18466

PR-URL: https://github.com/nodejs/node/pull/18472
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2018-02-06 11:29:18 +01:00
Yihong Wang
a89d215b79 build: fix coverage build
After adding the node_lib target in node.gyp, most of the node source
files are moved to that target. When coverage option is enabled,
corresponding cflags and ldflags are needed in that target as well.
gcovr also needs to check .gcda data for both node and node_lib.

PR-URL: https://github.com/nodejs/node/pull/18409
Fixes: https://github.com/nodejs/node/issues/18402
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2018-02-02 10:07:25 -05:00
Ben Noordhuis
09ef021bf4 build: fix rm commands in tarball rule
The `$(RM) {foo,bar,baz}` rules don't seem to work with GNU make 4.1.
Write them out in full and get rid of a few overlong lines in the
process.

PR-URL: https://github.com/nodejs/node/pull/18332
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2018-01-26 16:32:52 -05:00
Ben Noordhuis
56ee94f184
build: compile V8 using system compiler
Stop using the copy of clang that is bundled with Google's build tools
and start using the compiler that is installed on the buildbots.
It stopped working on one of the machines because it looked in the
wrong place for system headers and is not representative of how users
build Node.js on their systems.

PR-URL: https://github.com/nodejs/node/pull/17489
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
2018-01-24 15:02:41 -08:00
Michaël Zasso
e9bcb39ef2
build: remove --no-i18n from V8 test options
The option was removed in [1] to use compiler option instead.

[1]: 0b9acc20e2

PR-URL: https://github.com/nodejs/node/pull/17489
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
2018-01-24 15:02:38 -08:00
Rod Vagg
57bd27eda8 Revert "build,test: make building addon tests less fragile"
This reverts commit d9b59def72.

Breaks downloadable source tarball builds as we remove some files prior
to creating a tarball but those files are included in the comprehensive
list of dependencies listed in .deps.

Ref: https://github.com/nodejs/node/pull/17407
PR-URL: https://github.com/nodejs/node/pull/18287
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-01-25 08:18:24 +11:00
Rod Vagg
d5d024d6ec Revert "build,tools: check freshness of doc addons"
This reverts commit 2cb9e2a6f7.

Reverted along with d9b59def7 as this introduces freshness checks that
are too stringent without the comprehensive dependency checking of
introduced in d9b59def7 so `make test` won't work with this.

Ref: https://github.com/nodejs/node/pull/17407
PR-URL: https://github.com/nodejs/node/pull/18287
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-01-25 08:17:53 +11:00
Joyee Cheung
13bc53fb26
build: make lint-js independent of local node
PR-URL: https://github.com/nodejs/node/pull/18272
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-24 03:49:54 +08:00
Joyee Cheung
be0778b361
build: make lint-md independent of local node
PR-URL: https://github.com/nodejs/node/pull/18272
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-24 03:49:42 +08:00
Ben Noordhuis
2cb9e2a6f7
build,tools: check freshness of doc addons
Add a `--check` flag to `tools/doc/addon-verify.js` and use that in the
`make test` target to determine if the generated files in `test/addons`
are fresh or stale.

PR-URL: https://github.com/nodejs/node/pull/17407
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2018-01-21 02:19:47 +01:00
Ben Noordhuis
d9b59def72
build,test: make building addon tests less fragile
* Get rid of recursive `make` when building the node binary.  An earlier
  commit makes GYP write out rules that we can use for proper dependency
  tracking.

* Use module name 'binding' in addons.md and addons-napi/*/binding.gyp.
  This massively simplifies the logic for generating the build rules.

* Check in auto-generated add-on tests from `doc/api/addons.md`.  The
  files change rarely and generating them dynamically causes no end of
  race conditions and special-casing during the build.

PR-URL: https://github.com/nodejs/node/pull/17407
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2018-01-21 02:19:46 +01:00
Joyee Cheung
0c8aaf318a
build: remove bench-* targets
PR-URL: https://github.com/nodejs/node/pull/18150
Fixes: https://github.com/nodejs/node/issues/17053
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-01-17 02:30:31 +08:00
Michael Dawson
8229fc0715 src: fix code coverage cleanup
In https://github.com/nodejs/node/pull/17987 which updated
the location of the code coverage patches I missed a few
changes needed to properly clean up for code coverage.  Add
these.

PR-URL: https://github.com/nodejs/node/pull/18081
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-16 10:50:46 -05:00
Michaël Zasso
3dc3063275 tools: move eslint from tools to tools/node_modules
This is required because we need to add the babel-eslint dependency
and it has to be able to resolve "eslint".
babel-eslint is required to support future ES features such as async
iterators and import.meta.

Refs: https://github.com/nodejs/node/pull/17755
PR-URL: https://github.com/nodejs/node/pull/17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2018-01-11 09:48:05 +01:00
Yang Guo
a2c7085dd4 build: fix Makefile wrt finding node executable
Not all shells set PWD, so use CURDIR instead.

`which node` may return the empty string, so guard against
that too. Consider:
if [ -x `which velociraptor` ] && [ -e `which velociprator` ];\
then echo "run"; else echo "keep calm"; fi;

PR-URL: https://github.com/nodejs/node/pull/18040
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2018-01-11 07:52:21 +01:00
Joyee Cheung
d64279b4ee
build: document targets in the Makefile
PR-URL: https://github.com/nodejs/node/pull/16975
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
2018-01-09 17:07:19 +08:00
Michael Dawson
c91bd2f24f src: update make for new code coverage locations
The files for code coverage are moving to the build
repository.  Update the references to reflect this.

PR-URL: https://github.com/nodejs/node/pull/17987
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-01-08 18:20:13 -05:00
Oky Antoro
feaf6ac3dc
build: put .PHONY directly before its target
Before this change, the .PHONY is followed by multiple targets.
Now it is multiple .PHONY for each target.

PR-URL: https://github.com/nodejs/node/pull/17964
Refs: https://github.com/nodejs/node/issues/16968
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-05 12:52:49 +01:00
Rich Trott
f05fb0104a build: remove duplicate async-hooks and known_issues test runs
The `default` test suite in `test.py` includes `async-hooks` and
`known_issues`. Our current setup results in those test suites being run
twice during each CI run. Remove the duplication.

PR-URL: https://github.com/nodejs/node/pull/17912
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-02 20:50:14 -08:00
Refael Ackermann
51a7d97625
tools: don't lint-md as part of main lint target
PR-URL: https://github.com/nodejs/node/pull/17587
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-12-11 11:53:28 -05:00
Gibson Fahnestock
d865395b7d
build: add a make help option for common targets
PR-URL: https://github.com/nodejs/node/pull/17323
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-12-09 08:04:59 +00:00
Michaël Zasso
6c47033024
build: fix test-v8 target
Clean the deps/v8 directory before rebuilding node for the hash seed
test. It is necessary to avoid the script added in [1] to use ignored
files while generating `node-debug-support.cc`.

[1]: https://github.com/nodejs/node/pull/14901

PR-URL: https://github.com/nodejs/node/pull/17269
Fixes: https://github.com/nodejs/node-v8/issues/26
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
2017-11-29 10:46:54 +09:00
Joyee Cheung
7dc24062fc
build: add make lint-js-fix
PR-URL: https://github.com/nodejs/node/pull/17283
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2017-11-28 02:42:29 +01:00
Richard Littauer
887e2327ee
tools: fix gitignore for tools/doc/
PR-URL: https://github.com/nodejs/node/pull/17224
Fixes: https://github.com/nodejs/node/issues/17216
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2017-11-24 10:24:37 -05:00