Luigi Pinca
bc0a33070f
test: refactor and deflake test-tls-sni-server-client
...
- Run all tests in parallel.
- Move `socket.end()` call to client.
- Use `common.mustCall()` and `common.mustNotCall()`.
Fixes: https://github.com/nodejs/node/issues/27219
Refs: https://github.com/nodejs/node/pull/27300
PR-URL: https://github.com/nodejs/node/pull/27426
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-05-02 00:19:39 -07:00
Gilles De Mey
e5c8be2bd0
module: allow passing a directory to createRequireFromPath
...
Fixes: https://github.com/nodejs/node/issues/23710
PR-URL: https://github.com/nodejs/node/pull/23818
Reviewed-By: Guy Bedford <guybedford@gmail.com >
Reviewed-By: Myles Borins <myles.borins@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-05-01 17:34:12 -07:00
ptaylor
b884ceb518
fs: align fs.ReadStream buffer pool writes to 8-byte boundary
...
Prevents alignment issues when creating a typed array from a buffer.
Fixes: https://github.com/nodejs/node/issues/24817
PR-URL: https://github.com/nodejs/node/pull/24838
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-05-02 01:42:03 +02:00
Ruben Bridgewater
caf9d3c1d0
test: make sure weak references are not GCed too early
...
This fixes flaky `util.inspect` tests by making sure that the
inspected WeakMap and WeakSet only contains objects that still have
other hard references. Otherwise the garbage collection could collect
these objects to early.
PR-URL: https://github.com/nodejs/node/pull/27482
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-05-02 00:55:36 +02:00
Ruben Bridgewater
4416127482
buffer,errors: improve bigint, big numbers and more
...
This improves the error message from `ERR_OUT_OF_RANGE` by closer
inspecting the value and logging numbers above 2 ** 32 by adding
commas to the output for integer and bigint. BigInt is now also
marked if used.
Buffer errors also format the range as 2 ** n instead of showing a
huge number.
PR-URL: https://github.com/nodejs/node/pull/27228
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2019-05-01 12:29:04 +02:00
imhype
aacc046e6b
test: add mustcall in test-net-bytes-read.js
...
* add mustcall() on createServerListener
* add mustcall() on listenPortListener
* add mustCall() on onConnectListener
* add mustCallAtLeast() on onDataListener
PR-URL: https://github.com/nodejs/node/pull/27471
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
Reviewed-By: Masashi Hirano <shisama07@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-30 20:38:22 -07:00
Ruwan Geeganage
64284aad38
fs: added tests for util file preprocessSymlinkDestination
...
PR-URL: https://github.com/nodejs/node/pull/27468
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Masashi Hirano <shisama07@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-30 19:04:47 -07:00
Luigi Pinca
351a252db5
test: remove flaky designation for test-tls-sni-option
...
Refs: https://github.com/nodejs/node/pull/27300
PR-URL: https://github.com/nodejs/node/pull/27425
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-30 13:26:39 -07:00
Shuhei Kagawa
e4e6a33e6a
test: add missing line breaks to keep-alive header of slow headers test
...
PR-URL: https://github.com/nodejs/node/pull/27442
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-04-30 13:11:08 -07:00
Ruben Bridgewater
3d2409c476
test: add tests for new language features
...
PR-URL: https://github.com/nodejs/node/pull/27400
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2019-04-30 16:22:57 +02:00
Fedor Indutny
98e9de7db9
http: servername === false should disable SNI
...
There is no way to disable SNI extension when sending a request to HTTPS
server. Setting `options.servername` to a falsy value would make Node.js
core override it with either hostname or ip address.
This change introduces a way to disable SNI completely if this is
required for user's application. Setting `options.servername` to ``
in `https.request` would disable overrides and thus disable the
extension.
PR-URL: https://github.com/nodejs/node/pull/27316
Reviewed-By: Steven R Loomis <srloomis@us.ibm.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2019-04-30 06:43:22 -07:00
sujunfei
1001433e86
test: add mustCall for parallel/test-net-connect-paused-connection
...
Add common.mustCall test on net.createServer callback and listen
callback in the parallel/test-net-connect-paused-connection
remove the mustCall of net.createServer callback
PR-URL: https://github.com/nodejs/node/pull/27463
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-30 20:44:48 +08:00
heben
cb41430668
test: add mustCallAtLeast to test-fs-read-stream-resume.js
...
add mustCallAtLeast to test-fs-read-stream-resume.js
PR-URL: https://github.com/nodejs/node/pull/27456
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-30 17:14:32 +08:00
陈健
9c2774e613
test: adding mustCall in test-fs-readfile-empty.js
...
PR-URL: https://github.com/nodejs/node/pull/27455
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-30 17:12:14 +08:00
OneNail
578b31e14b
test: add common.mustCall in test-http-abort-client.js
...
PR-URL: https://github.com/nodejs/node/pull/27449
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-30 17:08:18 +08:00
Yaphet Ye
0fbd852578
test: add mustCall to http-abort-queued test
...
PR-URL: https://github.com/nodejs/node/pull/27447
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-30 17:04:17 +08:00
sinoon
034a568502
test: add mustCall in test-fs-readfilesync-pipe-large.js
...
PR-URL: https://github.com/nodejs/node/pull/27458
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-30 10:16:51 +08:00
XGHeaven
92ab466b74
test: add mustCall to test-dgram-connect-send-multi-buffer-copy.js
...
PR-URL: https://github.com/nodejs/node/pull/27465
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
2019-04-30 10:14:16 +08:00
Daiki Ihara
a565853ddd
test: add test of policy about parse error
...
PR-URL: https://github.com/nodejs/node/pull/26873
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-29 15:48:39 -07:00
xuqinggang
095bd569ae
test: add mustCall to test-net-after-close test
...
PR-URL: https://github.com/nodejs/node/pull/27459
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-29 14:59:47 -07:00
Sam Roberts
adedbb12e5
tls: allow enabling the TLS debug trace
...
Enable the same trace output that the OpenSSL s_client and s_server
support with their `-trace` option. This is invaluable when debugging
reports of TLS bugs as well as when debugging the internal TLS
implementation.
See:
- https://github.com/nodejs/node/issues/25383
- https://github.com/nodejs/node/issues/17936
- https://github.com/postmanlabs/postman-app-support/issues/5918#issuecomment-465311423
PR-URL: https://github.com/nodejs/node/pull/27376
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2019-04-29 10:57:55 -07:00
Anna Henningsen
cc7b3fbaab
child_process: only stop readable side of stream passed to proc
...
Closing the underlying resource completely has the unwanted side effect
that the stream can no longer be used at all, including passing it
to other child processes.
What we want to avoid is accidentally reading from the stream;
accordingly, it should be sufficient to stop its readable side
manually, and otherwise leave the underlying resource intact.
Fixes: https://github.com/nodejs/node/issues/27097
Refs: https://github.com/nodejs/node/pull/21209
PR-URL: https://github.com/nodejs/node/pull/27373
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
2019-04-29 20:01:27 +05:30
wuchenkai
413256d5e8
test: add "mustCall" to test-fs-readfile-unlink
...
Add common.mustCall to test-fs-readfile-unlink
PR-URL: https://github.com/nodejs/node/pull/27453
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-29 20:50:55 +08:00
nilianzhu
f5e2ad784f
test: add mustCallAtLeast to test-fs-read-stream-inherit
...
PR-URL: https://github.com/nodejs/node/pull/27457
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-29 14:22:19 +08:00
Chenxi Yuan
c3d4933210
test: add mustCall to test-dgram-implicit-bind.js
...
PR-URL: https://github.com/nodejs/node/pull/27452
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-29 14:20:00 +08:00
zhoujiamin
eecf100049
test: add common.mustCall test-dgram-listen-after-bind
...
PR-URL: https://github.com/nodejs/node/pull/27454
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-29 14:17:56 +08:00
shenchen
77b9007395
test: add mustCall to test-dgram-connect-send-callback-buffer
...
PR-URL: https://github.com/nodejs/node/pull/27466
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-29 13:56:49 +08:00
hardfist
4cf8b4212c
test: add mustCallAtLeast to test-fs-read-stream-fd test
...
PR-URL: https://github.com/nodejs/node/pull/27461
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-04-29 13:19:26 +08:00
Daniel Bevenius
274364580a
test: skip fs-copyfile-respect-permission if root
...
Currently, if this test is run as the root user the following
failure will occur:
=== release test-fs-copyfile-respect-permissions ===
Path: parallel/test-fs-copyfile-respect-permissions
assert.js:89
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Missing expected exception (check).
at Object.<anonymous>
(/node/test/parallel/test-fs-copyfile-respect-permissions.js:38:10)
at Module._compile (internal/modules/cjs/loader.js:759:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
at Module.load (internal/modules/cjs/loader.js:628:32)
at Function.Module._load (internal/modules/cjs/loader.js:555:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:826:10)
at internal/main/run_main_module.js:17:11
Command:
out/Release/node test/parallel/test-fs-copyfile-respect-permissions.js
[05:41|% 100|+ 2620|- 1]: Done
This commit adds a root user check and skips this test if running as the
user root.
PR-URL: https://github.com/nodejs/node/pull/27378
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-04-29 05:32:34 +02:00
Anto Aravinth
d69f004657
repl: add autocomplete for filesystem modules
...
PR-URL: https://github.com/nodejs/node/pull/26648
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-04-29 07:28:27 +05:30
xinyulee
2c7b5332d6
test: add mustCall to net-can-reset-timeout
...
PR-URL: https://github.com/nodejs/node/pull/27462
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-29 07:07:47 +08:00
luoyu
54c973cee7
test: add mustCall to test-fs-readfile-pipe-large
...
PR-URL: https://github.com/nodejs/node/pull/27460
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-29 01:14:46 +08:00
lixin.atom
7cbbd51479
test: add "mustCall" for test-net-buffersize
...
PR-URL: https://github.com/nodejs/node/pull/27451
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
2019-04-29 01:10:33 +08:00
tongshouyu
a4fff9a72f
test: add mustCall to test-net-eaddrinuse test
...
PR-URL: https://github.com/nodejs/node/pull/27448
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-29 01:06:16 +08:00
jyjunyz
558e5c4367
test: add mustcall in test-dgram-connect-send-callback-buffer-length
...
add mustcall() on client.bind callback
PR-URL: https://github.com/nodejs/node/pull/27464
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Ouyang Yadong <oyydoibh@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-29 00:04:56 +08:00
tonyhty
fa3714d721
test: add mustCall to test-fs-readfile-pipe
...
PR-URL: https://github.com/nodejs/node/pull/27450
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-28 23:32:57 +08:00
Rongjian Zhang
73a686f1bb
test: add mustCall to net-connect-buffer test
...
PR-URL: https://github.com/nodejs/node/pull/27446
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-04-28 23:24:08 +08:00
Ruben Bridgewater
31b3dd2842
tools: prohibit assert.doesNotReject() in Node.js core
...
This makes sure we do not use `assert.doesNotReject()` anywhere in
our code base. This is just a simple wrapper that catches the
rejection and then rejects it again in case of an error. Thus, it is
not useful to do that.
The error message for `assert.doesNotThrow()` is also improved.
PR-URL: https://github.com/nodejs/node/pull/27402
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-27 18:22:27 +02:00
Steven R. Loomis
31ac8b9080
deps: backport ICU-20575 to fix err/crasher
...
- Floating patch for ICU 64.x
- includes test case
ICU Bug: https://unicode-org.atlassian.net/browse/ICU-20575
Backport of: https://github.com/unicode-org/icu/pull/634
Fixes: https://github.com/nodejs/node/issues/27418
PR-URL: https://github.com/nodejs/node/pull/27435
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2019-04-27 11:54:13 +02:00
Steven R. Loomis
617c55ebe5
deps: backport ICU-20558 to fix Intl crasher
...
- Floating patch for ICU 63.x and 64.x
- fixing crash in Intl when ICU data not found.
- Regression test from refack included.
Background:
- ICU-13778 (landed in ICU 63.1) fixed a bug but
added a regression.
- a recent v8 land in Node v12 (which one?) exposes
this bug to cause a crash when ICU data is not found.
ICU Bug: https://unicode-org.atlassian.net/browse/ICU-20558
Backport of: https://github.com/unicode-org/icu/pull/632
Fixes: https://github.com/nodejs/node/issues/27379
Co-authored-by: Refael Ackermann <refack@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/27415
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
2019-04-27 11:40:16 +02:00
Luigi Pinca
f7afed17b6
test: move test-net-connect-handle-econnrefused
...
The port used in the test could be taken by another process before
the callback of `server.close()` is called. Move it to sequential.
PR-URL: https://github.com/nodejs/node/pull/27014
Fixes: https://github.com/nodejs/node/issues/26907
Refs: https://github.com/nodejs/node/pull/18257#discussion_r162717096
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2019-04-27 08:20:21 +02:00
Sam Roberts
86b4f3729a
tls: include invalid method name in thrown error
...
When an invalid TLS method name error is thrown, include the invalid
name in the error message.
PR-URL: https://github.com/nodejs/node/pull/27390
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Brian White <mscdex@mscdex.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-26 10:38:38 -07:00
Ruben Bridgewater
1d022e8253
process: improve cwd performance
...
This caches the current working directory and only updates the variable
if `process.chdir()` is called.
PR-URL: https://github.com/nodejs/node/pull/27224
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2019-04-26 18:43:11 +02:00
Ruben Bridgewater
55147d7d99
util: add prototype support for boxed primitives
...
This makes sure manipulated prototypes from boxed primitives will
be highlighted. It also makes sure that a potential `Symbol.toStringTag`
is taken into account.
PR-URL: https://github.com/nodejs/node/pull/27351
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com >
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com >
2019-04-26 18:23:45 +02:00
Sam Roberts
6bbb9ebf8d
test: rework to remove flakiness, and be parallel
...
Let .end() propogate from client, to server, and back, before
considering the test complete. Also, remove the test vector and exit
handling in favour of running all the tests in parallel and using
common.must/mustNotCall().
PR-URL: https://github.com/nodejs/node/pull/27300
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
2019-04-25 10:09:53 -07:00
Ruben Bridgewater
2f1add18a4
util: improve Symbol.toStringTag handling
...
Only special handle `Symbol.toStringTag` if the property is not
enumerable or not the own property of the inspected object.
PR-URL: https://github.com/nodejs/node/pull/27342
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-04-25 08:27:03 +02:00
Joyee Cheung
b9f1e57201
lib: throw a special error in internal/assert
...
Instead of using the public AssertionError, use a simplified
error that describes potential causes of these assertions
and suggests the user to open an issue.
PR-URL: https://github.com/nodejs/node/pull/26635
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-04-25 01:29:48 +02:00
Masashi Hirano
fb3f6005c0
test: fix ineffective error tests
...
Fix tests whether errors are thrown correctly
because they are successful when error doesn't get thrown.
PR-URL: https://github.com/nodejs/node/pull/27333
Fixes: https://github.com/nodejs/node/issues/26385
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-04-24 10:07:09 +02:00
Rich Trott
9b982feedf
test: make test-worker-esm-missing-main more robust
...
test-worker-esm-missing-main failed in CI recently in a way that
suggests that maybe the `does-not-exist.js` file did in fact exist.
Maybe that isn't what happened at all, but let's rule it out by changing
the use of `does-not-exist.js` from a file expected to be missing from
the current working directory to a file in the temp directory, which the
test will remove and recreate at the outset.
PR-URL: https://github.com/nodejs/node/pull/27340
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
2019-04-23 22:40:46 -07:00
Rich Trott
eac8f50ca6
test: increase coverage in lib/internal/dns/promises.js
...
Add a test for the only uncovered code in lib/internal/dns/promises.js.
PR-URL: https://github.com/nodejs/node/pull/27330
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2019-04-23 13:04:14 -07:00