You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

16 lines
448 B

var request = require('../index')
, http = require('http')
, assert = require('assert')
;
var s = http.createServer(function (req, resp) {
resp.statusCode = 200;
resp.end('asdf');
}).listen(8080, function () {
request({'url': 'http://localhost:8080', 'pool': false}, function (e, resp) {
var agent = resp.request.agent;
assert.strictEqual(typeof agent, 'boolean');
assert.strictEqual(agent, false);
s.close();
});
});