node/test/parallel/test-http-client-encoding.js
Rich Trott c36ca37e2a test: remove unused variables form http tests
The http tests seem especially prone to including unused variables.
This change removes them.

PR-URL: https://github.com/nodejs/node/pull/4422
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
2016-01-06 12:10:43 -05:00

19 lines
328 B
JavaScript

'use strict';
var common = require('../common');
var http = require('http');
http.createServer(function(req, res) {
res.end('ok\n');
this.close();
}).listen(common.PORT, test);
function test() {
http.request({
port: common.PORT,
encoding: 'utf8'
}, function(res) {
res.pipe(process.stdout);
}).end();
}