test if the connection can be established with the given host and port

npm install connection-tester
3 downloads in the last week
6 downloads in the last month


Build Status

Sync/Blocking test to check if the connection can be established or host/port reachable for a given host and port. Useful for testing all the connection in your node application at server startup.

How to Use

var connectionTester = require('connection-tester');

console.log(connectionTester.test('', 80));
console.log(connectionTester.test('', 443));
npm loves you