Commit Graph

48 Commits

Author SHA1 Message Date
Marc Ghorayeb
ad093c1036 [node] homogenize zlib input to Buffer or string and results to Buffer 2017-08-15 14:36:40 +02:00
Dimitri Benin
5a3249593e [node] improve util.deprecate() typings, fix tests in v4 & v6 for TS >=2.3 (#18903)
* [node] improve util.deprecate() typings, fix tests in v4 & v6 for TS >=2.3

* [react-measure, react-svg-pan-zoom] fix lint errors

* [node] change deprecate() typings in v7, too
2017-08-14 11:18:10 -07:00
Flarna
34d4afebc1 [node] Update async_hooks according to renaming done in 8.2.0 (#18530)
- currentId() => executionAsyncId()
- triggerId() => triggerAsyncId()

see https://github.com/nodejs/node/pull/13490
2017-08-01 10:49:41 -07:00
Deividas Bakanas
417f73ad32 [node] undefined type added to properties of dictionaries. Some TSLint TODOs resolved. (#18372)
* `undefined` type added to properties of dictionaries;
Formatting fixed;
TSLint TODOs resolved:
- adjacent-overload-signatures;
- align;
- array-type;
- callable-types;
- comment-format;
- dt-header;
- import-spacing;
- interface-over-type-literal;
- jsdoc-format;
- no-consecutive-blank-lines;
- no-padding;
- no-string-throw;
- object-literal-shorthand;
- one-line;
- only-arrow-functions;
- semicolon;
- whitespace.

* `NodeRequireFunction` `type` reverted to `interface`.
2017-07-31 13:57:11 -07:00
william chang(張仲威)
b269ac560f [node] http.server add property keepAliveTimeout (#18385) 2017-07-25 12:42:02 -07:00
Andy
af8b0d1294 FIx new lint errors (#18382) 2017-07-25 10:34:23 -07:00
william chang(張仲威)
dfda34b1c2 [node] net.Server, http.Server, http.ServerRequest, http.ServerResponse, http.ClientRequest, http.IncomingMessage, http.ClientResponse fix from interface to class and add constructors. (#18281)
* [node] net.Server, http.Server, http.ServerRequest, http.ServerResponse, http.ClientRequest, http.IncomingMessage, http.ClientResponse, http.Server fix from interface to class and add constructors.

* add http constructor tests

* fix lint

* add author

* fix: remove rejectUnauthorized,
createConnection callback make more detailed,
http.Server requestListener more detailed,
add export OutgoingMessage, ServerResponse and ClientRequest extends OutgoingMessage.
combine the constructors in ClientRequest

* add more http tests

* remove trailing space

* remove deprecated apis, private props not documented, seperate httpHeaders to incoming and outgoing, fix rejectUnauthorized prop misplaced, use () => void for callback

* typo

* settimeout return this
2017-07-24 10:37:46 -07:00
Daniel Imms
527914c2a3 node: Fix net.Socket definition (#18275)
v0.12.x: https://nodejs.org/docs/latest-v0.12.x/api/net.html#net_new_net_socket_options
v4: https://nodejs.org/dist/latest-v4.x/docs/api/net.html#net_new_net_socket_options
v6: https://nodejs.org/dist/latest-v6.x/docs/api/net.html#net_new_net_socket_options
v7: https://nodejs.org/dist/latest-v7.x/docs/api/net.html#net_new_net_socket_options
v8: https://nodejs.org/api/net.html#net_new_net_socket_options
2017-07-21 09:41:56 -07:00
Ron Buckton
d00f967ff8 Improve types for node 'fs' module (#18052) 2017-07-20 15:54:19 -07:00
Ryan Cavanaugh
000e7a1135 Merge pull request #17978 from cjbarth/node/read-file-sync
NODE: Correct signature for readFileSync
2017-07-13 19:03:26 -07:00
Ryan Cavanaugh
60a364df1d Merge pull request #17959 from achugaev93/master
node: Updated definitions and tests for ChildProcess#send method
2017-07-13 16:46:48 -07:00
Barth, Christopher
4b8d8cea4d Update tests 2017-07-13 10:38:41 -04:00
Barth, Christopher
e373c4db6c Add tests and include readFile changes 2017-07-13 09:07:38 -04:00
Ryan Cavanaugh
ab73c5c1a3 Merge pull request #17528 from mwiktorczyk/master
Node.js v8.0.0 Stream - types/node/index.d.ts
2017-07-12 14:10:27 -07:00
Alex Chugaev
b9897281e3 Merge branch 'master' into master 2017-07-12 02:20:13 +03:00
chugaev
a3fb24fb08 node: Updated definitions and tests for ChildProcess#send method 2017-07-12 02:11:00 +03:00
chugaev
dc3ec8e3c2 node: Updated definitions and tests for ChildProcess#send method 2017-07-12 02:06:50 +03:00
Jarrad Whitaker
d0c01b30a6 loosen assert.fail 2017-07-11 18:47:05 +10:00
Mariusz Wiktorczyk
257300c98d Node.js v8.0.0 Stream 2017-07-04 15:44:47 +02:00
Augustin Peyrard
370d4fca00 fix: in node.readline cursorTo allows only x coordinate
Like this we are easily able to move in the current line with
absolute x-axis coordinate.
2017-07-01 19:15:50 -07:00
Paul van Brenk
9579267a28 Merge pull request #17564 from Flarna/node_async_hooks
[node] Add async_hooks module
2017-06-29 10:54:22 -07:00
Paul van Brenk
4d12d79360 Merge pull request #17559 from brianjleeofcl/master
[node] Add missing properties in util.promisify and util.inspect
2017-06-28 11:42:05 -07:00
Flarna
743175f9f2 Merge remote-tracking branch 'upstream/master' into node_async_hooks 2017-06-28 20:39:44 +02:00
Paul van Brenk
fca29bc6e7 Merge pull request #17562 from kimushu/fix-writefilesync
Add fs.writeFile(Sync) / fs.appendFile(Sync) overloads and tests
2017-06-28 11:22:18 -07:00
kimu_shu
1b5e242876 Add overloads for writeFile, appendFile and appendFileSync 2017-06-28 21:55:08 +09:00
Flarna
0d8b5f7688 [node] Add async_hooks module
see https://nodejs.org/dist/latest-v8.x/docs/api/async_hooks.html
2017-06-28 10:30:47 +02:00
kimu_shu
1205f064bd Add fs.writeFileSync overloads and tests 2017-06-28 11:58:50 +09:00
Brian Lee
a70a977fe4 Add additional tests 2017-06-27 17:22:48 -07:00
Sebastien PUECH
825083d238 Fixed the bind method for UDP. 2017-06-22 16:57:50 +02:00
Andy Hanson
96545154cc bittorrent-protocol: Use same default event handler as stream.Readable 2017-06-20 10:26:49 -07:00
Flarna
f743880056 Merge remote-tracking branch 'upstream/master' into node_process_signals 2017-06-20 01:10:26 +02:00
Flarna
74fd1f601d - Added dedicated types for listeners to avoid unneeded copy/paste.
- Added overloads for listen() to cover issue discussed in latest comments of #16705
2017-06-20 01:01:48 +02:00
Nathan Shively-Sanders
4874667de9 Fix primitive weak type errors
These weak type errors were not caught in TS 2.4 RC. The final TS 2.4
will catch weak type errors with primitives, so this PR fixes those
now-caught errors.
2017-06-15 11:46:46 -07:00
Flarna
5686653759 * remove catch-all variants for on/once/... in Process
* add "newListener" | "removeListener" variants
* correct emit() functions for "cluster"
* add some tests
2017-06-13 22:08:10 +02:00
Nathan Shively-Sanders
cd62ed775d Add 'message' to process.on (#17137)
It was omitted by mistake in #16705
2017-06-12 16:36:37 -07:00
Boris Cherny
4b35f5c6d1 Node: Update and add missing options for util#inspect (#16804)
* inspect depth should be nullable

* add showProxy, maxArrayLength, and breakLength options for util#inspect
2017-06-02 09:25:49 -07:00
Leonard Thieu
3f95ea32d7 [node] Narrow down type that can be passed to url.format(). (#16850)
* Narrow down type that can be passed to url.format().

* Add format(URL).

* [node] Fix build error.
universal-analytics package has invalid tslint.json.

* [node] Fix build error.
universal-analytics package has invalid version number.
2017-06-01 12:05:57 -07:00
Matus Gura
2c2b9e42c8 [node] Added missing on net.Socket (#16810) 2017-05-31 22:59:11 -07:00
Arthur Ozga
f4aad91a85 Merge pull request #16419 from Flarna/node_crypto_randomfill
[node] Add crypto.randomFillSync() and crypto.randomFill()
2017-05-19 16:59:54 -07:00
Flarna
4abd596e3c [node] Add more constructor options to url.URLSearchParams 2017-05-10 13:09:25 +02:00
Flarna
97ba49c9d1 Add crypto.randomFillSync() and crypto.randomFill() 2017-05-09 17:56:56 +02:00
Parambir Singh
67b6964441 Add a few missing type definitions for node.js zlib module (#16311)
* Update index.d.ts

Add overloaded methods for zlib module that take a ZlibOptions parameter along with a callback.

* Add tests for new methods added to node’s zlib module definition.
2017-05-04 17:44:38 -07:00
ikokostya
65989c0d61 @types/node: update dns.resolve* declarations (#16320)
* @types/node: update dns.resolve* declarations

Fixes: #11151

* review fixes
2017-05-04 17:44:11 -07:00
ikokostya
90cd78deeb @types/node: fix dns.lookup() definitions (#15900)
* @types/node: fix dns.lookup() definitions

* fix optional family argument
2017-05-03 12:09:15 -07:00
kadler15
fd3da9791a Align test order 2017-03-25 11:14:49 -07:00
kadler15
330ccde014 Reverse signals and errno in node os.constants 2017-03-25 11:10:13 -07:00
Andy
508b2e7869 node: Change "disconnet" to "disconnect" (#15375) 2017-03-24 16:43:33 -07:00
Andy Hanson
354cec620d Move all packages to a types directory 2017-03-24 14:27:52 -07:00