chill117 / proxy-verifier

NodeJS module to check proxies: if functional, anonymity level, tunneling, supported protocols.
MIT License
76 stars 16 forks source link

Refactoring, improved options #17

Closed chill117 closed 7 years ago

chill117 commented 7 years ago

Can now run your own custom tests like this:

ProxyVerifier.test(proxy, {
    testUrl: 'https://www.google.com',
    testFn: function(data, status, headers) {

        // Check the response data, status, and headers.

        // Throw an error if the test failed.
        throw new Error('Test failed!');

        // Do nothing if the test passed.
    }
}, function(error, results) {
    // Do something with error or results.
});