projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d9c67ae
)
test: add TXT DNS record lookup test
author
Ben Noordhuis
<info@bnoordhuis.nl>
Mon, 3 Oct 2011 14:50:09 +0000
(16:50 +0200)
committer
Ben Noordhuis
<info@bnoordhuis.nl>
Mon, 3 Oct 2011 14:50:09 +0000
(16:50 +0200)
test/internet/test-dns.js
patch
|
blob
|
history
diff --git
a/test/internet/test-dns.js
b/test/internet/test-dns.js
index
f738ab6
..
28a7a2d
100644
(file)
--- a/
test/internet/test-dns.js
+++ b/
test/internet/test-dns.js
@@
-248,6
+248,18
@@
TEST(function test_resolveCname(done) {
});
+TEST(function test_resolveTxt(done) {
+ var req = dns.resolveTxt('google.com', function(err, records) {
+ if (err) throw err;
+ assert.equal(records.length, 1);
+ assert.equal(records[0].indexOf('v=spf1'), 0);
+ done();
+ });
+
+ checkWrap(req);
+});
+
+
TEST(function test_lookup_ipv4_explicit(done) {
var req = dns.lookup('www.google.com', 4, function(err, ip, family) {
if (err) throw err;