summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2019-04-30http: `servername === false` should disable SNIFedor Indutny
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-30test: add mustCall for parallel/test-net-connect-paused-connectionsujunfei
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-30test: add mustCallAtLeast to test-fs-read-stream-resume.jsheben
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-30test: 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-30test: add common.mustCall in test-http-abort-client.jsOneNail
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-30test: add mustCall to http-abort-queued testYaphet Ye
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-30test: add mustCall in test-fs-readfilesync-pipe-large.jssinoon
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-30test: add mustCall to test-dgram-connect-send-multi-buffer-copy.jsXGHeaven
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-29test: add test of policy about parse errorDaiki Ihara
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-29test: add mustCall to test-net-after-close testxuqinggang
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-29tls: allow enabling the TLS debug traceSam Roberts
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-29child_process: only stop readable side of stream passed to procAnna Henningsen
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-29test: add "mustCall" to test-fs-readfile-unlinkwuchenkai
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-29test: add missing ToC entriescjihrig
These modules were already documented, but not included in the table of contents. PR-URL: https://github.com/nodejs/node/pull/27434 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-04-29test: document report helper modulecjihrig
PR-URL: https://github.com/nodejs/node/pull/27434 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-04-29test: document NODE_SKIP_FLAG_CHECKcjihrig
PR-URL: https://github.com/nodejs/node/pull/27434 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-04-29test: document NODE_TEST_KNOWN_GLOBALScjihrig
PR-URL: https://github.com/nodejs/node/pull/27434 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-04-29test: add mustCallAtLeast to test-fs-read-stream-inheritnilianzhu
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-29test: add mustCall to test-dgram-implicit-bind.jsChenxi Yuan
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-29test: add common.mustCall test-dgram-listen-after-bindzhoujiamin
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-29test: add mustCall to test-dgram-connect-send-callback-buffershenchen
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-29test: add mustCallAtLeast to test-fs-read-stream-fd testhardfist
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-29test: skip fs-copyfile-respect-permission if rootDaniel Bevenius
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-29repl: add autocomplete for filesystem modulesAnto Aravinth
PR-URL: https://github.com/nodejs/node/pull/26648 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-04-29test: add mustCall to net-can-reset-timeoutxinyulee
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-29test: add mustCall to test-fs-readfile-pipe-largeluoyu
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-29test: add "mustCall" for test-net-buffersizelixin.atom
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-29test: add mustCall to test-net-eaddrinuse testtongshouyu
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-29test: add mustcall in test-dgram-connect-send-callback-buffer-lengthjyjunyz
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-28test: add mustCall to test-fs-readfile-pipetonyhty
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-28test: add mustCall to net-connect-buffer testRongjian Zhang
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-28process: reduce the number of internal frames in async stack traceJoyee Cheung
Previously, we call the JS land `runNextTicks` implementation immediately from JS land after evaluating the main module or the input, so these synchronous JS call frames would show up in the stack trace of the async errors, which can be confusing. This patch moves those calls into C++ so that more of these internal scheduler implementation details can be hidden and the users can see a cleaner a cleaner async JS stack trace. PR-URL: https://github.com/nodejs/node/pull/27392 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Minwoo Jung <minwoo@nodesource.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2019-04-28benchmark: add benchmark for node -pJoyee Cheung
PR-URL: https://github.com/nodejs/node/pull/27320 Reviewed-By: James M Snell <jasnell@gmail.com>
2019-04-27tools: prohibit `assert.doesNotReject()` in Node.js coreRuben Bridgewater
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-27report: print common items first for readabilitygengjiawen
PR-URL: https://github.com/nodejs/node/pull/27367 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
2019-04-27deps: backport ICU-20575 to fix err/crasherSteven R. Loomis
- 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-27deps: backport ICU-20558 to fix Intl crasherSteven R. Loomis
- 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-27test: refactor net-connect-handle-econnrefusedLuigi Pinca
- Remove unneeded server - Use `common.PORT` PR-URL: https://github.com/nodejs/node/pull/27014 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2019-04-27test: move test-net-connect-handle-econnrefusedLuigi Pinca
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-26tls: include invalid method name in thrown errorSam Roberts
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-26process: improve cwd performanceRuben Bridgewater
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-26util: add prototype support for boxed primitivesRuben Bridgewater
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-26src: use predefined AliasedBuffer types in the code baseJoyee Cheung
Instead of allowing the callers to instantiate the template with any numeric types (such as aliasing a Uint8Array to double[]), predefine types that make sense and use those instead. PR-URL: https://github.com/nodejs/node/pull/27334 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com>
2019-04-25test: rework to remove flakiness, and be parallelSam Roberts
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-25util: improve `Symbol.toStringTag` handlingRuben Bridgewater
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-25lib: throw a special error in internal/assertJoyee Cheung
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-24n-api: do not require JS Context for `napi_async_destroy()`Anna Henningsen
Allow the function to be called during GC, which is a common use case. Fixes: https://github.com/nodejs/node/issues/27218 PR-URL: https://github.com/nodejs/node/pull/27255 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2019-04-24test: fix ineffective error testsMasashi Hirano
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-23test: make test-worker-esm-missing-main more robustRich Trott
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-23test: increase coverage in lib/internal/dns/promises.jsRich Trott
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>