Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
fixup
  • Loading branch information
ronag committed Aug 21, 2021
commit 62c026f9cbec66528332a6a5200201b90e8cf352
2 changes: 1 addition & 1 deletion test/parallel/test-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ assert.strictEqual(util.isFunction(function() {}), true);
assert.strictEqual(util.isFunction(), false);
assert.strictEqual(util.isFunction('string'), false);

assert.strictEqual(util.toUSVString('string'), 'string');
assert.strictEqual(util.toUSVString('string\ud801'), 'string\ufffd');

@mathiasbynens mathiasbynens Aug 26, 2021

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally we’d test lone lead surrogates, lone trail surrogates, and also surrogate pairs (to ensure those are unaffected). Patch: #39891


{
assert.strictEqual(util.types.isNativeError(new Error()), true);
Expand Down