Skip to content

Commit

Permalink
test: improve assertion message in internet dgram test
Browse files Browse the repository at this point in the history
When an error occurs unexpectedly, let the user know what the error is.

PR-URL: #30545
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
Trott authored and MylesBorins committed Dec 17, 2019
1 parent 574b0f2 commit d802393
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/internet/test-dgram-send-cb-quelches-error.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ function callbackOnly(err) {
}

function onEvent(err) {
assert.fail('Error should not be emitted if there is callback');
assert.fail(`Error should not be emitted if there is callback: ${err}`);
}

function onError(err) {
Expand Down

0 comments on commit d802393

Please sign in to comment.