test: check custom inspection truncation in assert
The assert module has some truncation logic in a custom inspect function. This was not covered in tests. Add tests to cover it.
The previously-uncovered lines are https://github.com/nodejs/node/blob/b6148402d461ffb70446ddd4b55051e093ad1aef/lib/internal/assert/assertion_error.js#L437-L442.
@BridgeAR I could use some confirmation that this is covering a feature and not revealing a bug. When an ASSERTION_ERROR
with a long line is inspected, the value in actual
or expected
will be truncated but the same value will appear in full in the message
. Whoops? Or by design?
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
commit message follows commit guidelines