Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit fe5ea3f

Browse filesBrowse files
Trottaddaleax
authored andcommitted
test: check callback not invoked on lookup error
Use `common.mustNotCall()` to confirm that callback is not invoked when `dns.lookup()` throws. PR-URL: #13456 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
1 parent 216cb3f commit fe5ea3f
Copy full SHA for fe5ea3f

File tree

Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed
Open diff view settings
Collapse file

‎test/parallel/test-dns-lookup.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-dns-lookup.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,15 @@ assert.throws(() => {
2424
hints: 100,
2525
family: 0,
2626
all: false
27-
}, common.noop);
27+
}, common.mustNotCall());
2828
}, /^TypeError: Invalid argument: hints must use valid flags$/);
2929

3030
assert.throws(() => {
3131
dns.lookup(false, {
3232
hints: 0,
3333
family: 20,
3434
all: false
35-
}, common.noop);
35+
}, common.mustNotCall());
3636
}, /^TypeError: Invalid argument: family must be 4 or 6$/);
3737

3838
assert.doesNotThrow(() => {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.