lib: enforce use of trailing commas

PR-URL: https://github.com/nodejs/node/pull/46881
Reviewed-By: Debadree Chatterjee <debadree333@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Jacob Smith <jacob@frende.me>
This commit is contained in:
Antoine du Hamel committed 2023-03-06 10:44:14 +01:00
1 parent 57909654a9
commit ab8942848b
65 files changed
+246 -280

No files matched your search

+5 -5
View File
@@ -38,7 +38,7 @@ const kReadableOperator = {
'Expected "actual" not to be reference-equal to "expected":',
notDeepEqual: 'Expected "actual" not to be loosely deep-equal to:',
notIdentical: 'Values have same structure but are not reference-equal:',
notDeepEqualUnequal: 'Expected values not to be loosely deep-equal:'
notDeepEqualUnequal: 'Expected values not to be loosely deep-equal:',
};
// Comparing short primitives should just show === / !== instead of using the
@@ -330,11 +330,11 @@ class AssertionError extends Error {
stackStartFn,
details,
// Compatibility with older versions.
stackStartFunction
stackStartFunction,
} = options;
let {
actual,
expected
expected,
} = options;
const limit = Error.stackTraceLimit;
@@ -429,7 +429,7 @@ class AssertionError extends Error {
value: 'AssertionError [ERR_ASSERTION]',
enumerable: false,
writable: true,
configurable: true
configurable: true,
});
this.code = 'ERR_ASSERTION';
if (details) {
@@ -478,7 +478,7 @@ class AssertionError extends Error {
const result = inspect(this, {
...ctx,
customInspect: false,
depth: 0
depth: 0,
});
// Reset the properties after inspection.