Emanuel Buholzer
51d8fd3d4e
doc: fix broken link in COLLABORATOR_GUIDE.md
...
PR-URL: https://github.com/nodejs/node/pull/10337
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
2016-12-21 08:32:32 -05:00
Anna Henningsen
beca3244e2
buffer: allow Uint8Array input to methods
...
Allow all methods on `buffer` and `Buffer` to take `Uint8Array`
arguments where it makes sense. On the native side, there is
effectively no difference, and as a bonus the `isUint8Array`
check is faster than `instanceof Buffer`.
PR-URL: https://github.com/nodejs/node/pull/10236
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Trevor Norris <trev.norris@gmail.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
2016-12-21 07:48:14 +01:00
Rich Trott
6cb33c0764
test: refactor test-timers-this
...
* use common.mustCall() and eliminate exit handler
* provide timer durtion of 1ms where previously omitted
* var -> const
PR-URL: https://github.com/nodejs/node/pull/10315
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2016-12-20 22:17:15 -08:00
cjihrig
ffd01da0f2
2016-12-20, Version 7.3.0 (Current)
...
Notable changes:
* buffer:
- buffer.fill() now works properly for the UCS2 encoding on
Big-Endian machines.
(Anna Henningsen) https://github.com/nodejs/node/pull/9837
* cluster:
- disconnect() now returns a reference to the disconnected
worker. (Sean Villars)
https://github.com/nodejs/node/pull/10019
* crypto:
- The built-in list of Well-Known CAs (Certificate Authorities)
can now be extended via a NODE_EXTRA_CA_CERTS environment
variable. (Sam Roberts)
https://github.com/nodejs/node/pull/9139
* http:
- Remove stale timeout listeners in order to prevent a memory leak
when using keep alive. (Karl Böhlmark)
https://github.com/nodejs/node/pull/9440
* tls:
- Allow obvious key/passphrase combinations. (Sam Roberts)
https://github.com/nodejs/node/pull/10294
* url:
- Including base argument in URL.originFor() to meet specification
compliance. (joyeecheung)
https://github.com/nodejs/node/pull/10021
- Improve URLSearchParams to meet specification compliance.
(Timothy Gu) https://github.com/nodejs/node/pull/9484
PR-URL: https://github.com/nodejs/node/pull/10277
2016-12-20 16:43:12 -05:00
misterpoe
ba4847e879
src: Node Tracing Controller
...
This commit adds support for trace-event tracing to Node.js. It provides
a mechanism to centralize tracing information generated by V8, Node
core, and userspace code. It includes:
- A trace writer responsible for serializing traces and cycling the
output files so that no individual file becomes to large.
- A buffer for aggregating traces to allow for batched flushes.
- An agent which initializes the tracing controller and ensures that
trace serialization is done on a separate thread.
- A set of macros for generating trace events.
- Tests and documentation.
Author: Raymond Kang <raymondksi@gmail.com >
Author: Kelvin Jin <kelvinjin@google.com >
Author: Matthew Loring <mattloring@google.com >
Author: Jason Ginchereau <jasongin@microsoft.com >
PR-URL: https://github.com/nodejs/node/pull/9304
Reviewed-By: Trevor Norris <trev.norris@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Josh Gavant <josh.gavant@outlook.com >
2016-12-20 12:31:09 -08:00
Italo A. Casas
613798335c
test: stream readable resumeScheduled state
...
PR-URL: https://github.com/nodejs/node/pull/10299
Ref: https://github.com/nodejs/node/issues/8683
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-20 11:23:35 -05:00
Bill Ticehurst
7a0fe9f471
win,msi: add required UIRef for localized strings
...
Reviewed-By: João Reis <reis@janeasystems.com >
PR-URL: https://github.com/nodejs/node/pull/8884
2016-12-20 14:41:23 +00:00
Sam Roberts
7b924f1713
doc: fix typo in ecdhCurve, a tls property name
...
Addresses comment after PR #6933 merged.
https://github.com/nodejs/node/pull/6933#pullrequestreview-13318708
PR-URL: https://github.com/nodejs/node/pull/10345
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-20 06:29:37 -08:00
Francis Gulotta
1081f0f33d
fs: remove needless assignment of null
...
This line `pool = null;` isn't needed and has
been around since the first iteration of streams.
I can't find a good reason for it to exist, it's
not more readable, nor does it seem to trick the
compiler into any optimizations.
PR-URL: https://github.com/nodejs/node/pull/10260
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-19 20:05:22 -05:00
Adrian Estrada
15c71f6c66
test: improve code in test-fs-open.js
...
* use const and let instead of var
* use assert.strictEqual instead of assert.equal
* use assert.strictEqual instead of assert.ok
* use assert.ifError
PR-URL: https://github.com/nodejs/node/pull/10312
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2016-12-19 20:03:17 -05:00
Matt Loring
a308a2fae4
deps: cherry-pick 081fce3 from V8 upstream
...
Original commit message:
ThreadTicks::Now support for Solaris
BUG=v8:5739
Review-Url: https://codereview.chromium.org/2576903004
Cr-Commit-Position: refs/heads/master@{#41771}
PR-URL: https://github.com/nodejs/node/pull/10342
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com >
2016-12-19 16:28:40 -08:00
Fedor Indutny
729fecf390
stream_base: homogenize req_wrap_obj use
...
Always use `req_wrap_obj` to allow calling `req->Done()` in stream
implementations.
PR-URL: https://github.com/nodejs/node/pull/10184
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-19 17:20:07 -05:00
Sam Roberts
0b44384561
tls: allow obvious key/passphrase combinations
...
Passphrase is now used whether keys are provided singly, in an array of
string/buffer, or an array of object, where it used to be ignored in
some argument combinations. Specifically, these now work as expected:
key: [encryptedPem],
passphrase: 'passphrase'
and
key: [{pem: encryptedPem}]
passphrase: 'passphrase'
and
key: [{pem: unencryptedPem}]
PR-URL: https://github.com/nodejs/node/pull/10294
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2016-12-19 13:42:56 -08:00
Santiago Gimeno
793d8719eb
test: fix flaky test-debug-port
...
It can happen that first data chunk received in stdout is not exactly
`'debug> '`. Make sure the exit condition is met.
PR-URL: https://github.com/nodejs/node/pull/10316
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-19 20:01:12 +01:00
Sean Villars
5d14602181
cluster: return worker reference from disconnect()
...
Changes disconnect() to return a refererence to the worker.
This will enable method chaining such as
worker.disconnect().once('disconnect', doThis);
PR-URL: https://github.com/nodejs/node/pull/10019
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
2016-12-19 09:46:31 -08:00
Adrian Estrada
5e781a3883
test: refactor the code in test-dns-ipv6
...
* remove the manual control for functions execution
* use common.mustCall to control the functions execution automatically
* use let and const instead of var
* use assert.strictEqual instead assert.equal
PR-URL: https://github.com/nodejs/node/pull/10219
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2016-12-19 06:53:25 -05:00
Adrian Estrada
8b367c5ddd
test: improve test-child-process-fork-and-spawn
...
* use const instead of var for required modules
* use assert.strictEqual instead of assert.equal
* remove unnecessary process.nextTick
PR-URL: https://github.com/nodejs/node/pull/10273
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-19 06:47:06 -05:00
Michaël Zasso
7cb98138a9
tools: forbid template literals in assert.throws
...
Extend the assert-throws-arguments custom ESLint rule to also check for
the use of template literals as a second argument to assert.throws.
PR-URL: https://github.com/nodejs/node/pull/10301
Ref: https://github.com/nodejs/node/pull/10282#discussion_r92607290
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-19 08:04:36 +01:00
Rich Trott
348e69c89d
test: fix flaky test-http-client-timeout-event
...
Race condition caused occasional failure on CI. Chained callbacks used
to remove race condition.
PR-URL: https://github.com/nodejs/node/pull/10293
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-18 20:58:43 -08:00
AnnaMag
0d3ac89ff7
test: add known_issues test for #6287
...
Deleting property in the vm context has no effect
as reported in https://github.com/nodejs/node/issues/6287
The test is moved to the known_issues and will be fixed
with the 5.5 V8 API changes.
PR-URL: https://github.com/nodejs/node/pull/10272
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-17 20:30:03 -05:00
Joe Doyle
92ed1ab450
build: change nosign flag to sign and flips logic
...
Makes the default build on Windows not try to sign the node.exe
binary after a build. Instead the 'sign' flag now indicates that the
binary should be signed. The 'nosign' flag is left as a noop.
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: João Reis <reis@janeasystems.com >
PR-URL: https://github.com/nodejs/node/pull/10156
2016-12-18 01:19:34 +00:00
Adrian Estrada
f7f662cad5
test: improve test-child-process-exec-buffer
...
* use const instead of var for required modules
* use assert.strictEqual instead of assert.equal
* use assert.strictEqual instead of assert.ok
PR-URL: https://github.com/nodejs/node/pull/10275
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-17 20:09:13 -05:00
weyj4
4a257568e2
test: clean up domain-no-error-handler test
...
Added duration to setTimeout and removed extraneous callback args,
as per Rich Trott's instructions
PR-URL: https://github.com/nodejs/node/pull/10291
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2016-12-17 09:36:30 +01:00
Adao Junior
9a347539a7
test: refactor domain test
...
Use assert.strictEqual() instead of assert.equal().
PR-URL: https://github.com/nodejs/node/pull/10269
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-16 21:18:42 -08:00
Outsider
4913acd364
test: use const/let and common.mustCall
...
remove process.on('exit') because all callbacks are
wrapped by common.mustCall.
PR-URL: https://github.com/nodejs/node/pull/9959
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-12-16 22:10:28 +01:00
Travis Bretton
4a08ac695c
test: cleanup test-stdout-close-catch.js
...
Added common.mustCall in child process on 'close' callback
Changed several 'var' statements to 'const' or 'let' where appropriate
Also linting
PR-URL: https://github.com/nodejs/node/pull/10006
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-12-16 22:08:31 +01:00
Michael Dawson
9de2adc04d
doc: fix broken link in COLLABORATOR_GUIDE.md
...
One of the links to CONTRIBUTING.md was broken in the doc.
Updated broken link to be the same as the other one in the
doc that was working.
PR-URL: https://github.com/nodejs/node/pull/10267
Reviewed-By: Sam Roberts <sam@strongloop.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
2016-12-16 21:58:45 +01:00
Alex Newman
40eba1270a
src: fix string format mistake for 32 bit node
...
warning: format ‘%lx’ expects argument of type ‘long
unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat=]
BIO_printf(bio, "0x%lx", exponent_word);
PR-URL: https://github.com/nodejs/node/pull/10082
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2016-12-16 14:34:19 -05:00
Aaron Williams
885c80f3de
test: refactor test-tls-ecdh-disable
...
* use common.mustCall()
* use String.prototype.includes() instead of String.prototype.indexOf()
PR-URL: https://github.com/nodejs/node/pull/9989
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2016-12-16 17:07:53 +01:00
mfrance
5a41a72b68
test: refactor test-dgram-send-callback-multi-buffer
...
* use assert.strictEqual() instead of assert.equal()
PR-URL: https://github.com/nodejs/node/pull/9999
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2016-12-16 15:43:27 +01:00
Joyee Cheung
8127501c3b
stream, test: test _readableState.emittedReadable
...
Part of #8683 , increase coverage of the internal
state machine of streams.
PR-URL: https://github.com/nodejs/node/pull/10249
See: https://github.com/nodejs/node/issues/8683
See: https://github.com/nodejs/node/issues/10230
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2016-12-16 10:16:54 +01:00
Rich Trott
31cb9a6170
doc: expand common module material in test guide
...
Provide a little more information about the `common` module. This
doesn't really provide much that wasn't already there, but hopefully
makes some things a bit more explicit for first-time readers.
PR-URL: https://github.com/nodejs/node/pull/10251
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2016-12-15 22:00:06 -08:00
Rich Trott
44e704f1f8
test: refactor test-fs-read-stream-inherit
...
Refactor to take advantage of block scoping to isolate tests. Checks in
exit handlers now reside with the relevant test block. Where test cases
start and end is more clear.
Also: Some use of `common.mustCall()` and improved wrapping/indentation.
PR-URL: https://github.com/nodejs/node/pull/10246
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2016-12-15 21:42:52 -08:00
Joyee Cheung
3daa4b1f76
test: stream readable needReadable state
...
PR-URL: https://github.com/nodejs/node/pull/10241
Ref: https://github.com/nodejs/node/issues/8683
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-15 22:25:42 -05:00
Lucas Holmquist
eceef76918
doc: document R CRAN mirror process
...
The current benchmark docs showing how to install R packages
doesn't go into how to specify a CRAN mirror.
This commit shows how to specify the repo parameter when
installing a package.
Fixes: https://github.com/nodejs/node/issues/10204
PR-URL: https://github.com/nodejs/node/pull/10211
Reviewed-By: Andreas Madsen <amwebdk@gmail.com >
2016-12-15 16:50:06 -05:00
Rich Trott
4a5c719be5
test: fix http-client-timeout-option-listeners
...
test-http-client-timeout-option-listeners is flaky due to depending on
completing operations before a 100ms socket timeout. The socket timeout
is an integral part of the test but can be very large. Set to the
maximum allowable value.
PR-URL: https://github.com/nodejs/node/pull/10224
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2016-12-14 12:45:20 -08:00
Andy Chen
e27c2a76a8
test: update test-domain-uncaught-exception.js
...
file: test/parallel/test-domain-uncaught-exception.js
1. There are three setTimeout() in the file and they do not specify a
duration (the second argument), so I change them to setImmediate()
instead.
2. There are four callbacks that take an argument called `err` but that
argument is never used, so I removed them.
PR-URL: https://github.com/nodejs/node/pull/10193
Reviewed-By: Sam Roberts <sam@strongloop.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2016-12-14 13:37:22 -05:00
Siddhartha Sahai
ca58e53047
test: refactor test-domain.js
...
apply setTimeout duration, add const, remove unused var
PR-URL: https://github.com/nodejs/node/pull/10207
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
2016-12-14 10:11:34 -08:00
Eugene Ostroukhov
3c29b2f851
inspector: fix Coverity defects
...
One defect remains - Coverity believes that a session object is never
freed while in reality its lifespan is tied to a libuv socket.
PR-URL: https://github.com/nodejs/node/pull/10240
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com >
2016-12-14 09:54:07 -08:00
Rich Trott
b79e83e7f6
test: refactor test-stream-big-push
...
* use common.mustCall()
* specify setTimeout() duration of 1ms
* remove unused `n` function argument
PR-URL: https://github.com/nodejs/node/pull/10226
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2016-12-14 10:14:39 -05:00
hveldstra
9f6f0f748c
timers: fix handling of cleared immediates
...
If current immediate has no callback, move on to the next one in
the queue.
Fixes: https://github.com/nodejs/node/issues/9756
PR-URL: https://github.com/nodejs/node/pull/9759
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2016-12-14 10:10:22 -05:00
Adrian Estrada
75ac109998
test: refactor test-http-dns-fail
...
* remove counter used to control function execution
* use commont.mustCall to control the function execution
* use const and let instead of var
* use arrow functions
PR-URL: https://github.com/nodejs/node/pull/10243
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Lance Ball <lball@redhat.com >
Reviewed-By: Brian White <mscdex@mscdex.net >
2016-12-14 10:06:18 -05:00
Ethan Arrowood
e432c2bfaa
fs: remove unused argument from copyObject()
...
The fs function copyObject() had two arguments:
source and target. On the first line of the function it
assigned the target variable to:
arguments.length >= 2 ? target : {};
The function copyObject() was not called directly by
any test, but it is called in other fs functions. When it
was called it was only ever called with a single argument,
source. Thus I have removed the target argument and assigned
it to an empty object like it was being assigned to in the
original ternary operator.
PR-URL: https://github.com/nodejs/node/pull/10041
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2016-12-14 15:17:03 +01:00
Brian White
f3cf8e9808
fs: do not pass Buffer when toString() fails
...
Even though an Error object is passed to the callback when readFile()
fails due to toString() failing, it is a bit strange to still see
data passed as the second argument. This commit changes that and only
passes the Error object in that case.
PR-URL: https://github.com/nodejs/node/pull/9670
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2016-12-14 03:29:33 -05:00
Jay Brownlee
4f97a146ff
url, test: fix typo in inspect output, add test
...
In the string returned from URL.inspect there was an extra semicolon
at the end when showHidden === true. The semicolon has been
removed and a test for the inspect function has been added. The test
parses the returned string, validates all of the contained keys/values
and tests logic related to the showHidden option.
PR-URL: https://github.com/nodejs/node/pull/10231
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Evan Lucas <evanlucas@me.com >
2016-12-14 05:20:42 +01:00
Rich Trott
9e92817119
test: refactor test-crypto-random
...
* specify constructor for assert.throws()
* load additional modules only if crypto check passes
* normalize some potentially confusing indentation
* provided actual first and expected second in assertions
PR-URL: https://github.com/nodejs/node/pull/10232
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2016-12-13 20:28:31 -05:00
Rich Trott
6f02957846
test: refactor test-http-pause-resume-one-end
...
* setTimeout() with no duration -> setImmediate()
* var -> const
* remove unused variable `chunk`
PR-URL: https://github.com/nodejs/node/pull/10210
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
2016-12-13 16:30:30 -08:00
Rich Trott
3ddbea6455
test: fix flaky test-dgram-exclusive-implicit-bind
...
test-dgram-exclusive-implicit-bind is written assuming that dgram
messages are received with 100% reliability. While missing a dgram
message sent to localhost is rare, we do see it as evidenced by CI
failures from time to time.
The test has been rewritten to send dgram messages over and over until
the test requirements have been met.
Additional incidental refactoring includes:
* var -> const
* use of common.mustCall() instead of exit listener + boolean
PR-URL: https://github.com/nodejs/node/pull/10212
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-13 16:41:12 -05:00
Adrian Estrada
e467d37ed9
test: improvements in test fixtures symlinked
...
- using strictEqual instead equal
- common dependency should be the first one
- using path.join instead relative path
PR-URL: https://github.com/nodejs/node/pull/10182
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
2016-12-13 16:29:44 -05:00
Rob Adelmann
34991be450
test: refactor test-fs-fsync
...
- replace var with const.
- remove successes var.
- use assert.ifError() for handling all errors.
- wrap all callbacks with common.mustCall().
PR-URL: https://github.com/nodejs/node/pull/10176
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Italo A. Casas <me@italoacasas.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
2016-12-13 15:59:35 -05:00