chenyc
2025-12-09 65e034683b28d799e73c7d7e5e4769fab5b9bc9c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
/**
 * In strict assertion mode, non-strict methods behave like their corresponding
 * strict methods. For example, `assert.deepEqual()` will behave like
 * `assert.deepStrictEqual()`.
 *
 * In strict assertion mode, error messages for objects display a diff. In legacy
 * assertion mode, error messages for objects display the objects, often truncated.
 *
 * To use strict assertion mode:
 *
 * ```js
 * import { strict as assert } from 'node:assert';
 * ```
 *
 * ```js
 * import assert from 'node:assert/strict';
 * ```
 *
 * Example error diff:
 *
 * ```js
 * import { strict as assert } from 'node:assert';
 *
 * assert.deepEqual([[[1, 2, 3]], 4, 5], [[[1, 2, '3']], 4, 5]);
 * // AssertionError: Expected inputs to be strictly deep-equal:
 * // + actual - expected ... Lines skipped
 * //
 * //   [
 * //     [
 * // ...
 * //       2,
 * // +     3
 * // -     '3'
 * //     ],
 * // ...
 * //     5
 * //   ]
 * ```
 *
 * To deactivate the colors, use the `NO_COLOR` or `NODE_DISABLE_COLORS`
 * environment variables. This will also deactivate the colors in the REPL. For
 * more on color support in terminal environments, read the tty
 * [`getColorDepth()`](https://nodejs.org/docs/latest-v24.x/api/tty.html#writestreamgetcolordepthenv) documentation.
 * @since v15.0.0
 * @see [source](https://github.com/nodejs/node/blob/v24.x/lib/assert/strict.js)
 */
declare module "assert/strict" {
    import {
        Assert,
        AssertionError,
        AssertionErrorOptions,
        AssertOptions,
        AssertPredicate,
        AssertStrict,
        CallTracker,
        CallTrackerCall,
        CallTrackerReportInformation,
        deepStrictEqual,
        doesNotMatch,
        doesNotReject,
        doesNotThrow,
        fail,
        ifError,
        match,
        notDeepStrictEqual,
        notStrictEqual,
        ok,
        partialDeepStrictEqual,
        rejects,
        strictEqual,
        throws,
    } from "node:assert";
    function strict(value: unknown, message?: string | Error): asserts value;
    namespace strict {
        export {
            Assert,
            AssertionError,
            AssertionErrorOptions,
            AssertOptions,
            AssertPredicate,
            AssertStrict,
            CallTracker,
            CallTrackerCall,
            CallTrackerReportInformation,
            deepStrictEqual,
            deepStrictEqual as deepEqual,
            doesNotMatch,
            doesNotReject,
            doesNotThrow,
            fail,
            ifError,
            match,
            notDeepStrictEqual,
            notDeepStrictEqual as notDeepEqual,
            notStrictEqual,
            notStrictEqual as notEqual,
            ok,
            partialDeepStrictEqual,
            rejects,
            strict,
            strictEqual,
            strictEqual as equal,
            throws,
        };
    }
    export = strict;
}
declare module "node:assert/strict" {
    import strict = require("assert/strict");
    export = strict;
}