mirror of https://github.com/lukechilds/node.git
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.
17 lines
407 B
17 lines
407 B
11 years ago
|
var common = require('../common');
|
||
|
var assert = require('assert');
|
||
|
var http = require('http');
|
||
|
|
||
|
http.createServer(function(req, res) {
|
||
|
res.end('ok');
|
||
|
this.close();
|
||
11 years ago
|
}).listen(common.PORT, '127.0.0.1', function() {
|
||
11 years ago
|
var req = http.request({
|
||
|
method: 'POST',
|
||
11 years ago
|
host: '127.0.0.1',
|
||
|
port: common.PORT,
|
||
11 years ago
|
});
|
||
|
req.flush(); // Flush the request headers.
|
||
|
req.flush(); // Should be idempotent.
|
||
|
});
|