- Feb 28, 2017
-
-
Rich Trott authored
One downside to `common.expectsError()` is that it increases the abstractions people have to learn about in order to work with even simple tests. Whereas before, all they had to know about is `assert.throws()`, now they have to *also* know about `common.expectsError()`. This is very different (IMO) from `common.mustCall()` in that the latter has an intuitively understandable name, accepts arguments as one would expect, and (in most cases) doesn't actually require reading documentation or code to figure out what it's doing. With `common.expectsError()`, there's a fair bit of magic. Like, it's not obvious what the first argument would be. Or the second. Or the third. You just have to know. This PR changes the arguments accepted by `common.expectsError()` to a single settings object. Someone coming across this has a hope of understanding what's going on without reading source or docs: ```js const validatorFunction = common.expectsError({code: 'ELOOP', type: Error, message: 'foo'}); ``` This, by comparison, is harder to grok: ```js const validatorFunction = common.expectsError('ELOOP', Error, 'foo'); ``` And this is especially wat-inducing: ```js common.expectsError(undefined, undefined, 'looped doodad found'); ``` It's likely that only people who work with tests frequently can be expected to remember the three arguments and their order. By comparison, remembering that the error code is `code` and the message is `message` might be manageable. PR-URL: https://github.com/nodejs/node/pull/11512 Reviewed-By:James M Snell <jasnell@gmail.com> Reviewed-By:
Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com>
-
Arseniy Maximov authored
* Change === to == in one place * Add explanation about another non-strict if-statement PR-URL: https://github.com/nodejs/node/pull/11513 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Sebastian Van Sande authored
Modify the `[Writable]` and `[Readable]` links so they point directly to the right sections in the stream.html doc PR-URL: https://github.com/nodejs/node/pull/11517 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com>
-
Zach Bjornson authored
Add documentation for http clientRequest.aborted. PR-URL: https://github.com/nodejs/node/pull/11544 Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Rich Trott authored
Communicate about leaked globals via `AssertionError` rather than `console.log()`. PR-URL: https://github.com/nodejs/node/pull/11547 Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Amelia Clarke authored
Refs: https://github.com/nodejs/node/issues/9399 PR-URL: https://github.com/nodejs/node/pull/11548 Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
- Feb 27, 2017
-
-
Howard Hellyer authored
Setting the process title has been enabled in libuv on AIX and z/OS. The latest level of libuv skips only skips testing of uv_set_process_title when __sun is #defined. This change simplifies the skip test so the test is only skipped when common.isSunOS is true to match libuv. Skip running the `ps` part of the test on Windows. PR-URL: https://github.com/nodejs/node/pull/11416 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By:
Michael Dawson <michael_dawson@ca.ibm.com>
-
All the other headings are in level 3. This patch fixes the offending heading to use level 3. PR-URL: https://github.com/nodejs/node/pull/11569 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Joyee Cheung authored
Use the term "Abstract Equality Comparison" and "Strict Equality Comparison" from ECMAScript specification to refer to the operations done by `==` and `===`, instead of "equal comparison operator" and "strict equality operator". Clarify that deep strict comparisons checks `[[Prototype]]` property, instead of the vague "object prototypes". Suggest using `Object.is()` to avoid the caveats of +0, -0 and NaN. Add a MDN link explaining what enumerable "own" properties are. PR-URL: https://github.com/nodejs/node/pull/11128 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Michaël Zasso <targos@protonmail.com>
-
Joyee Cheung authored
Refactors _deepEqual and fixes a few code paths that lead to behaviors contradicting what the doc says. Before this commit certain types of objects (Buffers, Dates, etc.) are not checked properly, and can get away with different prototypes AND different enumerable owned properties because _deepEqual would jump to premature conclusion for them. Since we no longer follow CommonJS unit testing spec, the checks for primitives and object prototypes are moved forward for faster failure. Improve regexp and float* array checks: * Don't compare lastIndex of regexps, because they are not enumerable, so according to the docs they should not be compared * Compare flags of regexps instead of separate properties * Use built-in tags to test for float* arrays instead of using instanceof Use full link to the archived GitHub repository. Use util.objectToString for future improvements to that function that makes sure the call won't be tampered with. PR-URL: https://github.com/nodejs/node/pull/11128 Refs: https://github.com/nodejs/node/pull/10282#issuecomment-274267895 Refs: https://github.com/nodejs/node/issues/10258#issuecomment-266963234 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Rich Trott <rtrott@gmail.com> Reviewed-By:
Michaël Zasso <targos@protonmail.com>
-
- Feb 26, 2017
-
-
Joyee Cheung authored
Add a `test-addons-clean` to the Makefile to clean up files generated during testing addons. PR-URL: https://github.com/nodejs/node/pull/11519 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Myles Borins <myles.borins@gmail.com>
-
Brian White authored
PR-URL: https://github.com/nodejs/node/pull/11522 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Matteo Collina <matteo.collina@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Brian White authored
PR-URL: https://github.com/nodejs/node/pull/11516 Reviewed-By:
Jackson Tian <shyvo1987@gmail.com> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Michael Dawson <michael_dawson@ca.ibm.com>
-
- Feb 25, 2017
-
-
levsthings authored
Fixing a typo in comments, the word 'remaining' had a typo. PR-URL: https://github.com/nodejs/node/pull/11503 Fixes: https://github.com/nodejs/node/issues/11491 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com>
-
James M Snell authored
Doc-only deprecation of the undocumented res.writeHeader() API. Also makes res.writeHeader an alias of res.writeHead since the previous implementation simply deferred to that method. PR-URL: https://github.com/nodejs/node/pull/11355 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Rod Vagg <rod@vagg.org> Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
-
Timothy Gu authored
PR-URL: https://github.com/nodejs/node/pull/11464 Reviewed-By:
Steven R Loomis <srloomis@us.ibm.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Timothy Gu authored
- Templatize AsBuffer() and create a generic version for inclusion in the Buffer class - Use MaybeStackBuffer::storage() - If possible, avoid double conversion in ToASCII()/ToUnicode() - More descriptive assertion error in tests PR-URL: https://github.com/nodejs/node/pull/11464 Reviewed-By:
Steven R Loomis <srloomis@us.ibm.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Timothy Gu authored
- Add IsInvalidated() method - Add capacity() method for finding out the actual capacity, not the current size, of the buffer - Make IsAllocated() work for invalidated buffers - Allow multiple calls to AllocateSufficientStorage() and Invalidate() - Assert buffer is malloc'd in Release() - Assert buffer has not been invalidated in AllocateSufficientStorage() - Add more descriptive comments describing the purpose of the methods - Add cctest for MaybeStackBuffer PR-URL: https://github.com/nodejs/node/pull/11464 Reviewed-By:
Steven R Loomis <srloomis@us.ibm.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Timothy Gu authored
PR-URL: https://github.com/nodejs/node/pull/11464 Reviewed-By:
Steven R Loomis <srloomis@us.ibm.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Luigi Pinca authored
This adds an anchor for v6.10.0 in the LTS column. PR-URL: https://github.com/nodejs/node/pull/11534 Reviewed-By:
Evan Lucas <evanlucas@me.com> Reviewed-By:
Myles Borins <myles.borins@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Michael Dawson <michael_dawson@ca.ibm.com>
-
Rich Trott authored
* Remove comment referring to the CommonJS Unit Testing 1.0 spec. This module is no longer intended to comply with that spec. * Remove puzzling "THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8!" comment. No doubt, it made sense at one time. * Favor `===` over `==` in two places. PR-URL: https://github.com/nodejs/node/pull/11511 Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com>
-
Kunal Pathak authored
The intention of test case is to make sure that `timeout` property is honored and the code in context terminates and throws correct exception. However in test case, the code inside context would complete before `timeout` for windows and would sometimes fail. Updated the code so it guarantee to not complete execution until timeout is triggered. Fixes: https://github.com/nodejs/node/issues/11261 PR-URL: https://github.com/nodejs/node/pull/11530 Reviewed-By: James M Snell <jasnell.gmail.com> Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Josh Gavant <josh.gavant@outlook.com>
-
Diego Rodríguez Baquero authored
The IPC channel is referenced with the message event too. PR-URL: https://github.com/nodejs/node/pull/11494 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
- Feb 24, 2017
-
-
JungMinu authored
PR-URL: https://github.com/nodejs/node/pull/11473 Ref: https://github.com/nodejs/node/pull/11199#issuecomment-281184439 Reviewed-By:
Daniel Bevenius <daniel.bevenius@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Karan Thakkar authored
The fg(1) links in the readline docs have moved from `http://man7.org/linux/man-pages/man1/fg.1.html` to `http://man7.org/linux/man-pages/man1/fg.1p.html`. It also modifies the regex for replacing man page links in docs by allowing optional character after number. eg: fg(1) and fg(1p) will both be now parsed and replaced. Fixes: https://github.com/nodejs/node/issues/11492 PR-URL: https://github.com/nodejs/node/pull/11504 Reviewed-By:
Anna Henningsen <anna@addaleax.net> Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com>
-
Brian White authored
Creating an object in JS and using a typed array to transfer values from C++ to JS is faster than creating an object and setting properties in C++. The included benchmark shows ~34% increase in performance with this change. PR-URL: https://github.com/nodejs/node/pull/11497 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com>
-
Daijiro Wachi authored
+ Check an empty substring: In `querystring`, if the `maxKeys` is 1 and the state machine finds an empty substring between separators, it should return an empty object. + Test invalid encoded strings: If provided string is an invalid encoded string in `query.parse`, it will not be encoded. PR-URL: https://github.com/nodejs/node/pull/11481 Reviewed-By:
Timothy Gu <timothygu99@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-
Anna Henningsen authored
PR-URL: https://github.com/nodejs/node/pull/11489 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Sam Roberts <vieuxtech@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Italo A. Casas <me@italoacasas.com>
-