mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
Fix test-c-ares.js on Windows by disabling PTR test
This commit is contained in:
@@ -49,8 +49,12 @@ dns.lookup('ipv6.google.com', function(error, result, addressType) {
|
||||
assert.equal(6, addressType);
|
||||
});
|
||||
|
||||
dns.resolve('127.0.0.1', 'PTR', function(error, domains) {
|
||||
if (error) throw error;
|
||||
assert.ok(Array.isArray(domains));
|
||||
});
|
||||
|
||||
// Windows doesn't usually have an entry for localhost 127.0.0.1 in
|
||||
// C:\Windows\System32\drivers\etc\hosts
|
||||
// so we disable this test on Windows.
|
||||
if (process.platform != 'win32') {
|
||||
dns.resolve('127.0.0.1', 'PTR', function(error, domains) {
|
||||
if (error) throw error;
|
||||
assert.ok(Array.isArray(domains));
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user