Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: replace Google servers with localhost #25694

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 3 additions & 6 deletions test/parallel/test-dns-setserver-when-querying.js
Expand Up @@ -4,10 +4,7 @@ const common = require('../common');

const dns = require('dns');

const goog = [
'8.8.8.8',
'8.8.4.4',
];
const localhost = [ '127.0.0.1' ];

{
// Fix https://github.com/nodejs/node/issues/14734
Expand All @@ -16,7 +13,7 @@ const goog = [
const resolver = new dns.Resolver();
resolver.resolve('localhost', common.mustCall());

common.expectsError(resolver.setServers.bind(resolver, goog), {
common.expectsError(resolver.setServers.bind(resolver, localhost), {
code: 'ERR_DNS_SET_SERVERS_FAILED',
message: /^c-ares failed to set servers: "There are pending queries\." \[.+\]$/g
});
Expand All @@ -26,6 +23,6 @@ const goog = [
dns.resolve('localhost', common.mustCall());

// should not throw
dns.setServers(goog);
dns.setServers(localhost);
}
}