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.
15 lines
367 B
15 lines
367 B
14 years ago
|
common = require('../common');
|
||
|
assert = common.assert
|
||
|
net = require('net');
|
||
|
|
||
|
var server1 = net.createServer(function (socket) {
|
||
|
});
|
||
|
var server2 = net.createServer(function (socket) {
|
||
|
});
|
||
|
server1.listen(31337);
|
||
|
server2.addListener('error', function(error) {
|
||
|
assert.equal(true, error.message.indexOf('EADDRINUSE') >= 0);
|
||
|
server1.close();
|
||
|
});
|
||
|
server2.listen(31337);
|