Skip to content

Commit

Permalink
benchmark: remove deprecated argument
Browse files Browse the repository at this point in the history
The benchmarks for dns.lookup() include calling it with an empty
hostname which results in a deprecation warning. This benchmark seems to
be subject to some odd side effects (see Ref below) and we probably
generally don't want to benchmark deprecated things by default anyway.
Remove the deprecated value from the default list. Bonus is that this
will speed up the benchmark.

Refs: nodejs#27081 (comment)

PR-URL: nodejs#27091
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
  • Loading branch information
Trott committed Apr 7, 2019
1 parent 21b739f commit 77dee25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion benchmark/dns/lookup.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const common = require('../common.js');
const lookup = require('dns').lookup;

const bench = common.createBenchmark(main, {
name: ['', '127.0.0.1', '::1'],
name: ['127.0.0.1', '::1'],
all: ['true', 'false'],
n: [5e6]
});
Expand Down

0 comments on commit 77dee25

Please sign in to comment.