mirror of https://github.com/lukechilds/node.git
Ryan Dahl
14 years ago
2 changed files with 20 additions and 1 deletions
@ -0,0 +1,19 @@ |
|||
var common = require('../common'); |
|||
net = require('net'); |
|||
assert = require('assert'); |
|||
|
|||
var address; |
|||
|
|||
var server = net.createServer(function (socket) { |
|||
}); |
|||
|
|||
server.listen(function() { |
|||
address = server.address(); |
|||
console.log("opened server on %j", address); |
|||
server.close(); |
|||
}); |
|||
|
|||
process.on('exit', function () { |
|||
assert.ok(address.port > 100); |
|||
}); |
|||
|
Loading…
Reference in new issue