You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-07 13:22:56 +03:00
Add test for auth_pass option submitted by hpeinar
This commit is contained in:
18
test.js
18
test.js
@@ -1962,6 +1962,24 @@ tests.auth = function () {
|
||||
});
|
||||
};
|
||||
|
||||
tests.auth2 = function () {
|
||||
var name = "AUTH2", client4, ready_count = 0;
|
||||
|
||||
client4 = redis.createClient(9006, "filefish.redistogo.com", {auth_pass: "664b1b6aaf134e1ec281945a8de702a9"});
|
||||
|
||||
// test auth, then kill the connection so it'll auto-reconnect and auto-re-auth
|
||||
client4.on("ready", function () {
|
||||
ready_count++;
|
||||
if (ready_count === 1) {
|
||||
client4.stream.destroy();
|
||||
} else {
|
||||
client4.quit(function (err, res) {
|
||||
next(name);
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
tests.reconnectRetryMaxDelay = function() {
|
||||
var time = new Date().getTime(),
|
||||
name = 'reconnectRetryMaxDelay',
|
||||
|
Reference in New Issue
Block a user