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

Add more tests

Add execution order tests
Fix flaky test
Add utils tests
Improve other tests
This commit is contained in:
Ruben Bridgewater
2016-02-25 02:37:42 +01:00
parent 614e35ab57
commit 4f3c4a2ef6
7 changed files with 210 additions and 12 deletions

View File

@@ -109,6 +109,25 @@ describe("rename commands", function () {
});
});
it("should also work prefixed commands", function (done) {
if (helper.redisProcess().spawnFailed()) this.skip();
client.end(true);
client = redis.createClient({
rename_commands: {
set: '807081f5afa96845a02816a28b7258c3'
},
parser: parser,
prefix: 'baz'
});
client.set('foo', 'bar');
client.keys('*', function(err, reply) {
assert.strictEqual(reply[0], 'bazfoo');
assert.strictEqual(err, null);
done();
});
});
});
});