@types/node 20.4.7 → 20.4.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- node/README.md +1 -1
- node/package.json +2 -2
- node/perf_hooks.d.ts +1 -1
- node/test.d.ts +19 -1
- node/ts4.8/test.d.ts +18 -0
node/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (https://nodejs.org/).
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Tue, 08 Aug 2023 20:32:42 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`
|
|
14
14
|
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "20.4.
|
|
3
|
+
"version": "20.4.9",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
|
6
6
|
"license": "MIT",
|
|
@@ -227,6 +227,6 @@
|
|
|
227
227
|
},
|
|
228
228
|
"scripts": {},
|
|
229
229
|
"dependencies": {},
|
|
230
|
-
"typesPublisherContentHash": "
|
|
230
|
+
"typesPublisherContentHash": "b2f4c2c06161f1c6a01968b024abf85b1541142467b4d7a7fe451165a706da3f",
|
|
231
231
|
"typeScriptVersion": "4.3"
|
|
232
232
|
}
|
node/perf_hooks.d.ts
CHANGED
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
*/
|
|
32
32
|
declare module 'perf_hooks' {
|
|
33
33
|
import { AsyncResource } from 'node:async_hooks';
|
|
34
|
-
type EntryType = 'node' | 'mark' | 'measure' | 'gc' | 'function' | 'http2' | 'http';
|
|
34
|
+
type EntryType = 'node' | 'mark' | 'measure' | 'gc' | 'function' | 'http2' | 'http' | 'dns';
|
|
35
35
|
interface NodeGCPerformanceDetail {
|
|
36
36
|
/**
|
|
37
37
|
* When `performanceEntry.entryType` is equal to 'gc', `the performance.kind` property identifies
|
node/test.d.ts
CHANGED
|
@@ -76,10 +76,11 @@
|
|
|
76
76
|
*
|
|
77
77
|
* If any tests fail, the process exit code is set to `1`.
|
|
78
78
|
* @since v18.0.0, v16.17.0
|
|
79
|
-
* @see [source](https://github.com/nodejs/node/blob/v20.
|
|
79
|
+
* @see [source](https://github.com/nodejs/node/blob/v20.4.0/lib/test.js)
|
|
80
80
|
*/
|
|
81
81
|
declare module 'node:test' {
|
|
82
82
|
import { Readable } from 'node:stream';
|
|
83
|
+
import { AsyncResource } from 'node:async_hooks';
|
|
83
84
|
/**
|
|
84
85
|
* ```js
|
|
85
86
|
* import { tap } from 'node:test/reporters';
|
|
@@ -295,6 +296,23 @@ declare module 'node:test' {
|
|
|
295
296
|
* For each test that is executed, any corresponding test hooks, such as `beforeEach()`, are also run.
|
|
296
297
|
*/
|
|
297
298
|
testNamePatterns?: string | RegExp | string[] | RegExp[];
|
|
299
|
+
/**
|
|
300
|
+
* A function that accepts the TestsStream instance and can be used to setup listeners before any tests are run.
|
|
301
|
+
*/
|
|
302
|
+
setup?: (root: Test) => void | Promise<void>;
|
|
303
|
+
/**
|
|
304
|
+
* Whether to run in watch mode or not. Default: false.
|
|
305
|
+
*/
|
|
306
|
+
watch?: boolean;
|
|
307
|
+
}
|
|
308
|
+
class Test extends AsyncResource {
|
|
309
|
+
concurrency: number;
|
|
310
|
+
nesting: number;
|
|
311
|
+
only: boolean;
|
|
312
|
+
reporter: TestsStream;
|
|
313
|
+
runOnlySubtests: boolean;
|
|
314
|
+
testNumber: number;
|
|
315
|
+
timeout: number | null;
|
|
298
316
|
}
|
|
299
317
|
/**
|
|
300
318
|
* A successful call to `run()` method will return a new `TestsStream` object, streaming a series of events representing the execution of the tests.`TestsStream` will emit events, in the
|
node/ts4.8/test.d.ts
CHANGED
|
@@ -80,6 +80,7 @@
|
|
|
80
80
|
*/
|
|
81
81
|
declare module 'node:test' {
|
|
82
82
|
import { Readable } from 'node:stream';
|
|
83
|
+
import { AsyncResource } from 'node:async_hooks';
|
|
83
84
|
/**
|
|
84
85
|
* ```js
|
|
85
86
|
* import { tap } from 'node:test/reporters';
|
|
@@ -295,6 +296,23 @@ declare module 'node:test' {
|
|
|
295
296
|
* For each test that is executed, any corresponding test hooks, such as `beforeEach()`, are also run.
|
|
296
297
|
*/
|
|
297
298
|
testNamePatterns?: string | RegExp | string[] | RegExp[];
|
|
299
|
+
/**
|
|
300
|
+
* A function that accepts the TestsStream instance and can be used to setup listeners before any tests are run.
|
|
301
|
+
*/
|
|
302
|
+
setup?: (root: unknown) => void | Promise<void>;
|
|
303
|
+
/**
|
|
304
|
+
* Whether to run in watch mode or not. Default: false.
|
|
305
|
+
*/
|
|
306
|
+
watch?: boolean;
|
|
307
|
+
}
|
|
308
|
+
class Test extends AsyncResource {
|
|
309
|
+
concurrency: number;
|
|
310
|
+
nesting: number;
|
|
311
|
+
only: boolean;
|
|
312
|
+
reporter: TestsStream;
|
|
313
|
+
runOnlySubtests: boolean;
|
|
314
|
+
testNumber: number;
|
|
315
|
+
timeout: number | null;
|
|
298
316
|
}
|
|
299
317
|
/**
|
|
300
318
|
* A successful call to `run()` method will return a new `TestsStream` object, streaming a series of events representing the execution of the tests.`TestsStream` will emit events, in the
|