1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00

Unify auth handling

This commit is contained in:
Ruben Bridgewater
2016-01-21 22:37:34 +01:00
parent 518e46dcc7
commit fb0eaf4d41
2 changed files with 25 additions and 37 deletions

View File

@@ -161,7 +161,7 @@ describe("client authentication", function () {
client = redis.createClient.apply(redis.createClient, args);
var async = true;
client.auth(undefined, function(err, res) {
assert.strictEqual(err.message, 'The password has to be of type "string"');
assert.strictEqual(err.message, 'ERR invalid password');
assert.strictEqual(err.command, 'AUTH');
assert.strictEqual(res, undefined);
async = false;
@@ -175,7 +175,7 @@ describe("client authentication", function () {
client = redis.createClient.apply(redis.createClient, args);
client.on('error', function (err) {
assert.strictEqual(err.message, 'The password has to be of type "string"');
assert.strictEqual(err.message, 'ERR invalid password');
assert.strictEqual(err.command, 'AUTH');
done();
});